aboutsummaryrefslogtreecommitdiff
path: root/juick-www/src/main/java/com
diff options
context:
space:
mode:
authorGravatar Vitaly Takmazov2017-03-03 10:10:23 +0300
committerGravatar Vitaly Takmazov2017-03-03 10:10:23 +0300
commit5ec9e5bff67957a796991a363b12d26698584b13 (patch)
treed5e3047edd31dbfb1e47d7b826e951b29b8b0074 /juick-www/src/main/java/com
parentcbf3ad834438a08bb6b9d5c2581eb59f61e69aed (diff)
juick-www: fix settings controller
Diffstat (limited to 'juick-www/src/main/java/com')
-rw-r--r--juick-www/src/main/java/com/juick/www/controllers/Settings.java3
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"))) {
;