aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/org/traccar/api/BaseObjectResource.java
diff options
context:
space:
mode:
authorAnton Tananaev <anton@traccar.org>2022-07-16 07:29:55 -0700
committerAnton Tananaev <anton@traccar.org>2022-07-16 07:29:55 -0700
commit16e63283a2b64b2e1b490701c219beed653f2b17 (patch)
tree630a85b5aa4d1498515e2380ed658d729b44b8a7 /src/main/java/org/traccar/api/BaseObjectResource.java
parent80bbf6e1b1903ba9218245c4fe94e5b482b59dad (diff)
downloadtrackermap-server-16e63283a2b64b2e1b490701c219beed653f2b17.tar.gz
trackermap-server-16e63283a2b64b2e1b490701c219beed653f2b17.tar.bz2
trackermap-server-16e63283a2b64b2e1b490701c219beed653f2b17.zip
Fix password update
Diffstat (limited to 'src/main/java/org/traccar/api/BaseObjectResource.java')
-rw-r--r--src/main/java/org/traccar/api/BaseObjectResource.java4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/main/java/org/traccar/api/BaseObjectResource.java b/src/main/java/org/traccar/api/BaseObjectResource.java
index 2a3bbe239..408594315 100644
--- a/src/main/java/org/traccar/api/BaseObjectResource.java
+++ b/src/main/java/org/traccar/api/BaseObjectResource.java
@@ -98,6 +98,10 @@ public abstract class BaseObjectResource<T extends BaseModel> extends BaseResour
storage.updateObject(entity, new Request(
new Columns.Exclude("id"),
new Condition.Equals("id", "id")));
+ if (entity instanceof User) {
+ storage.updateObject(entity, new Request(
+ new Columns.Include("hashedPassword", "salt"), new Condition.Equals("id", "id")));
+ }
cacheManager.updateOrInvalidate(true, entity);
LogAction.edit(getUserId(), entity);