diff options
Diffstat (limited to 'server.js')
-rw-r--r-- | server.js | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -455,6 +455,7 @@ const SQL_SELECT_USER_DYNAMIC = SQL("select * from user_dynamic_view where user_ const SQL_SELECT_USER_ID = SQL("SELECT user_id FROM users WHERE name=?").pluck() const SQL_SELECT_USER_BY_SEARCH = SQL("select name, atime from users left join user_last_seen using(user_id) where name like ? order by name") +const SQL_SELECT_USER_ABOUT = SQL("SELECT about FROM user_about WHERE user_id=?").pluck() const SQL_SELECT_USER_NOTIFY = SQL("SELECT notify FROM users WHERE user_id=?").pluck() const SQL_SELECT_USER_VERIFIED = SQL("SELECT is_verified FROM users WHERE user_id=?").pluck() const SQL_UPDATE_USER_NOTIFY = SQL("UPDATE users SET notify=? WHERE user_id=?") @@ -826,7 +827,7 @@ app.post("/change-mail", must_be_logged_in, function (req, res) { }) app.get("/change-about", must_be_logged_in, function (req, res) { - let about = SQL_SELECT_USER_PROFILE.get(req.user.name).about + let about = SQL_SELECT_USER_ABOUT.get(req.user.user_id) res.render("change_about.pug", { user: req.user, about: about || "" }) }) |