diff options
Diffstat (limited to 'src/main/java/com/juick/CommandsManager.java')
-rw-r--r-- | src/main/java/com/juick/CommandsManager.java | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/main/java/com/juick/CommandsManager.java b/src/main/java/com/juick/CommandsManager.java index 7488e331..a0f6e5e5 100644 --- a/src/main/java/com/juick/CommandsManager.java +++ b/src/main/java/com/juick/CommandsManager.java @@ -30,8 +30,8 @@ import java.util.regex.Matcher; import java.util.regex.Pattern; import java.util.stream.Collectors; -import javax.annotation.Nonnull; -import javax.inject.Inject; +import jakarta.annotation.Nonnull; +import jakarta.inject.Inject; import com.juick.model.CommandResult; import com.juick.model.Message; @@ -545,7 +545,7 @@ public class CommandsManager { } } Pair<String, Set<Tag>> messageTags = tagService.fromString(txt); - if (user.getUid() == msg.get().getUser().getUid() && rid == 0 && messageTags.getRight().size() > 0) { + if (user.getUid() == msg.get().getUser().getUid() && rid == 0 && !messageTags.getRight().isEmpty()) { var updatedTags = tagService.updateTags(mid, messageTags.getRight()); if (!CollectionUtils.isEqualCollection(updatedTags, msg.get().getTags())) { messagesService.setReadOnly(msg.get().getMid(), TagUtils.hasTag(updatedTags, "readonly")); @@ -554,6 +554,9 @@ public class CommandsManager { return CommandResult.fromString("Tags are NOT updated (5 tags maximum?)"); } } else { + if (!user.isVerified()) { + return CommandResult.fromString("Please, verify your account at https://juick.com/settings"); + } if (!messagesService.canViewThread(mid, user.getUid())) { return CommandResult.fromString("Message unavailable"); } |