diff options
Diffstat (limited to 'src/main/java/com/juick/www/controllers/Settings.java')
-rw-r--r-- | src/main/java/com/juick/www/controllers/Settings.java | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/main/java/com/juick/www/controllers/Settings.java b/src/main/java/com/juick/www/controllers/Settings.java index f2cd4aa9..bc6b6614 100644 --- a/src/main/java/com/juick/www/controllers/Settings.java +++ b/src/main/java/com/juick/www/controllers/Settings.java @@ -38,6 +38,7 @@ import com.juick.util.HttpBadRequestException; import com.juick.util.HttpUtils; import com.juick.www.WebApp; +import io.swagger.v3.oas.annotations.Parameter; import jakarta.mail.Message; import jakarta.mail.MessagingException; import jakarta.mail.Session; @@ -88,7 +89,7 @@ public class Settings { @GetMapping("/settings") protected String doGet( - @ModelAttribute User visitor, + @Parameter(hidden = true) User visitor, Locale locale, @RequestParam(required = false, defaultValue = "main") String page, @RequestParam(required = false) String code, ModelMap model) { @@ -125,7 +126,7 @@ public class Settings { @PostMapping("/settings") protected String doPost( - @ModelAttribute User visitor, + @Parameter(hidden = true) User visitor, HttpServletRequest request, HttpServletResponse response, @RequestParam(required = false) MultipartFile newAvatar, ModelMap model) @@ -271,7 +272,7 @@ public class Settings { } @PostMapping("/settings/unsubscribe") public String unsubscribeOneClick( - @ModelAttribute User user, + User user, @RequestParam(name = "List-Unsubscribe") String unsubscribe, ModelMap model) { if (!user.isAnonymous()) { |