diff options
Diffstat (limited to 'juick-common/src/main/java/com/juick/server')
-rw-r--r-- | juick-common/src/main/java/com/juick/server/CommandsManager.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/juick-common/src/main/java/com/juick/server/CommandsManager.java b/juick-common/src/main/java/com/juick/server/CommandsManager.java index 918e6028..d3be371f 100644 --- a/juick-common/src/main/java/com/juick/server/CommandsManager.java +++ b/juick-common/src/main/java/com/juick/server/CommandsManager.java @@ -145,7 +145,7 @@ public class CommandsManager { User user_to = userService.getUserByName(arguments[0]); - if (user_to.getUid() > 0) { + if (!user_to.isAnonymous()) { if (!userService.isInBLAny(user_to.getUid(), user_from.getUid())) { if (pmQueriesService.createPM(user_from.getUid(), user_to.getUid(), body)) { com.juick.Message jmsg = new com.juick.Message(); @@ -379,7 +379,7 @@ public class CommandsManager { public CommandResult commandUser(User user, URI attachment, String... arguments) { User blogUser = userService.getUserByName(arguments[0]); int page = arguments[1].length(); - if (blogUser.getUid() > 0) { + if (!blogUser.isAnonymous()) { List<Integer> mids = messagesService.getUserBlog(blogUser.getUid(), 0, 0); return CommandResult.fromString(String.format("Last messages from @%s:\n%s", arguments[0], printMessages(mids, false))); |