projects
/
oweals
/
peertube.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a5625b4
)
Fix avatar update
author
Chocobozzz
<me@florianbigard.com>
Thu, 4 Jan 2018 13:53:25 +0000
(14:53 +0100)
committer
Chocobozzz
<me@florianbigard.com>
Thu, 4 Jan 2018 13:53:25 +0000
(14:53 +0100)
server/controllers/api/users.ts
patch
|
blob
|
history
diff --git
a/server/controllers/api/users.ts
b/server/controllers/api/users.ts
index d8ecbdbe2f042b3663d22b59ef30e1cf807318ee..2d77a52494e0e1cec2813db66da6b164b232a2ae 100644
(file)
--- 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
await unlinkPromise(source)
const avatar = await sequelizeTypescript.transaction(async t => {
- await updateActorAvatarInstance(actor, avatarName, t)
+ const updatedActor = await updateActorAvatarInstance(actor, avatarName, t)
+ await updatedActor.save({ transaction: t })
await sendUpdateUser(user, t)
- return
a
vatar
+ return
updatedActor.A
vatar
})
return res