From 80063166dcd0bfbbc43f4be59061abc179edbaf9 Mon Sep 17 00:00:00 2001 From: Vitaly Takmazov Date: Tue, 20 Dec 2022 17:02:39 +0300 Subject: `updateUserInfo` fix --- src/main/java/com/juick/service/UserServiceImpl.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/com/juick/service/UserServiceImpl.java b/src/main/java/com/juick/service/UserServiceImpl.java index b9301d06..4158561c 100644 --- a/src/main/java/com/juick/service/UserServiceImpl.java +++ b/src/main/java/com/juick/service/UserServiceImpl.java @@ -401,7 +401,7 @@ public class UserServiceImpl extends BaseJdbcService implements UserService { info.getCountry(), info.getUrl(), info.getDescription()) > 0; - } catch (DuplicateKeyException e) { + } catch (DataIntegrityViolationException e) { return getJdbcTemplate().update("UPDATE usersinfo SET fullname = ?, country = ?, url = ?, descr = ? WHERE user_id = ?", info.getFullName(), info.getCountry(), -- cgit v1.2.3