diff options
author | 2017-03-03 10:10:23 +0300 | |
---|---|---|
committer | 2017-03-03 10:10:23 +0300 | |
commit | 5ec9e5bff67957a796991a363b12d26698584b13 (patch) | |
tree | d5e3047edd31dbfb1e47d7b826e951b29b8b0074 /juick-www/src/main/java/com/juick/www/controllers | |
parent | cbf3ad834438a08bb6b9d5c2581eb59f61e69aed (diff) |
juick-www: fix settings controller
Diffstat (limited to 'juick-www/src/main/java/com/juick/www/controllers')
-rw-r--r-- | juick-www/src/main/java/com/juick/www/controllers/Settings.java | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/juick-www/src/main/java/com/juick/www/controllers/Settings.java b/juick-www/src/main/java/com/juick/www/controllers/Settings.java index 6cafbb7e..c7c51820 100644 --- a/juick-www/src/main/java/com/juick/www/controllers/Settings.java +++ b/juick-www/src/main/java/com/juick/www/controllers/Settings.java @@ -80,6 +80,8 @@ public class Settings { EmailService emailService; @Inject TelegramService telegramService; + @Inject + MessagesService messagesService; @RequestMapping(value = "/settings", method = RequestMethod.GET) protected String doGet(HttpServletRequest request, HttpServletResponse response, ModelMap model) throws IOException { @@ -109,6 +111,7 @@ public class Settings { model.addAttribute("telegram_name", crosspostService.getTelegramName(visitor.getUid())); model.addAttribute("notify_options", subscriptionService.getNotifyOptions(visitor)); model.addAttribute("userinfo", userService.getUserInfo(visitor)); + model.addAttribute("readonly", messagesService.isReadonly()); if (page.equals("auth-email")) { if (emailService.verifyAddressByCode(visitor.getUid(), request.getParameter("code"))) { ; |