aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--server/controllers/api/users.ts5
1 files changed, 3 insertions, 2 deletions
diff --git a/server/controllers/api/users.ts b/server/controllers/api/users.ts
index d8ecbdbe2..2d77a5249 100644
--- a/server/controllers/api/users.ts
+++ b/server/controllers/api/users.ts
@@ -249,11 +249,12 @@ async function updateMyAvatar (req: express.Request, res: express.Response, next
249 await unlinkPromise(source) 249 await unlinkPromise(source)
250 250
251 const avatar = await sequelizeTypescript.transaction(async t => { 251 const avatar = await sequelizeTypescript.transaction(async t => {
252 await updateActorAvatarInstance(actor, avatarName, t) 252 const updatedActor = await updateActorAvatarInstance(actor, avatarName, t)
253 await updatedActor.save({ transaction: t })
253 254
254 await sendUpdateUser(user, t) 255 await sendUpdateUser(user, t)
255 256
256 return avatar 257 return updatedActor.Avatar
257 }) 258 })
258 259
259 return res 260 return res