diff options
author | Chocobozzz <me@florianbigard.com> | 2019-08-22 17:16:48 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2019-08-22 17:16:48 +0200 |
commit | 001ed2d40c8d2c8f494f5dc7f91ed62d56df10fd (patch) | |
tree | 9a88235affe49fce4b7ce2df192931cffaec32e9 /server/controllers/lazy-static.ts | |
parent | d5c8932a601c1854db0a2e399ccaf26e17385f1a (diff) | |
parent | 60c2bc80b82c71bd63bdb1fcf64d4d49491ce5c8 (diff) | |
download | PeerTube-001ed2d40c8d2c8f494f5dc7f91ed62d56df10fd.tar.gz PeerTube-001ed2d40c8d2c8f494f5dc7f91ed62d56df10fd.tar.zst PeerTube-001ed2d40c8d2c8f494f5dc7f91ed62d56df10fd.zip |
Merge branch 'release/1.4.0' into develop
Diffstat (limited to 'server/controllers/lazy-static.ts')
-rw-r--r-- | server/controllers/lazy-static.ts | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/server/controllers/lazy-static.ts b/server/controllers/lazy-static.ts index 28d2f862a..1ff99e90c 100644 --- a/server/controllers/lazy-static.ts +++ b/server/controllers/lazy-static.ts | |||
@@ -44,6 +44,8 @@ async function getAvatar (req: express.Request, res: express.Response) { | |||
44 | } | 44 | } |
45 | 45 | ||
46 | const avatar = await AvatarModel.loadByName(filename) | 46 | const avatar = await AvatarModel.loadByName(filename) |
47 | if (!avatar) return res.sendStatus(404) | ||
48 | |||
47 | if (avatar.onDisk === false) { | 49 | if (avatar.onDisk === false) { |
48 | if (!avatar.fileUrl) return res.sendStatus(404) | 50 | if (!avatar.fileUrl) return res.sendStatus(404) |
49 | 51 | ||