diff options
author | Vitaly Takmazov | 2016-06-27 14:10:16 +0300 |
---|---|---|
committer | Vitaly Takmazov | 2016-06-27 14:10:16 +0300 |
commit | 8a818bbd03913e7dc02430947b0fb1e5a950647a (patch) | |
tree | 064b554618489f58ff4ac56ad92db6538feb1560 /src/main/java/com/juick/http/www/User.java | |
parent | 8ecdfbd5a36c7cc4d48bb563c9b561a904033514 (diff) |
fixes
Diffstat (limited to 'src/main/java/com/juick/http/www/User.java')
-rw-r--r-- | src/main/java/com/juick/http/www/User.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main/java/com/juick/http/www/User.java b/src/main/java/com/juick/http/www/User.java index 51b3965f..0bdd910e 100644 --- a/src/main/java/com/juick/http/www/User.java +++ b/src/main/java/com/juick/http/www/User.java @@ -320,7 +320,7 @@ public class User { public static String pageUserTags(JdbcTemplate sql, com.juick.User user, com.juick.User visitor, int cnt) { List<Tag> tags = TagQueries.getUserTagsAll(sql, user.getUID()); - int maxUsageCnt = tags.stream().map(t -> t.UsageCnt).max(Integer::max).get(); + int maxUsageCnt = tags.stream().map(t -> t.UsageCnt).max(Integer::max).orElse(0); String ret = ""; int count = Math.min(tags.size(), cnt); for (int i = 0; i < count; i++) { |