aboutsummaryrefslogtreecommitdiff
path: root/juick-server/src/main/java
diff options
context:
space:
mode:
Diffstat (limited to 'juick-server/src/main/java')
-rw-r--r--juick-server/src/main/java/com/juick/service/UserServiceImpl.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/juick-server/src/main/java/com/juick/service/UserServiceImpl.java b/juick-server/src/main/java/com/juick/service/UserServiceImpl.java
index 1b33a6d3..0b8ed13b 100644
--- a/juick-server/src/main/java/com/juick/service/UserServiceImpl.java
+++ b/juick-server/src/main/java/com/juick/service/UserServiceImpl.java
@@ -640,7 +640,7 @@ public class UserServiceImpl extends BaseJdbcService implements UserService {
List<EmailOpts> list = getJdbcTemplate().query(
"SELECT email,subscr_hour FROM emails WHERE user_id=? AND subscr_hour IS NOT NULL",
(rs, num) -> new EmailOpts(rs.getString(1), rs.getInt(2)), user.getUid());
- return list.isEmpty() ? null : list.get(0);
+ return list.isEmpty() ? new EmailOpts("", 0) : list.get(0);
}
@Transactional(readOnly = true)