diff options
author | Chocobozzz <me@florianbigard.com> | 2021-01-26 10:23:21 +0100 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2021-01-26 10:29:57 +0100 |
commit | e08ff02a9f1fb1cfbdfa8f0f602eda9419ba6cc3 (patch) | |
tree | aea8add5a1a93edb0a5aab63588bd358aa9960a3 /server/initializers/constants.ts | |
parent | d223dca0cd50010d1c4455e5eec1736b1c591aed (diff) | |
download | PeerTube-e08ff02a9f1fb1cfbdfa8f0f602eda9419ba6cc3.tar.gz PeerTube-e08ff02a9f1fb1cfbdfa8f0f602eda9419ba6cc3.tar.zst PeerTube-e08ff02a9f1fb1cfbdfa8f0f602eda9419ba6cc3.zip |
Allow webp image uploads
Diffstat (limited to 'server/initializers/constants.ts')
-rw-r--r-- | server/initializers/constants.ts | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/server/initializers/constants.ts b/server/initializers/constants.ts index 453ca02ed..c06eb6fb0 100644 --- a/server/initializers/constants.ts +++ b/server/initializers/constants.ts | |||
@@ -264,7 +264,7 @@ const CONSTRAINTS_FIELDS = { | |||
264 | DESCRIPTION: { min: 3, max: 10000 }, // Length | 264 | DESCRIPTION: { min: 3, max: 10000 }, // Length |
265 | SUPPORT: { min: 3, max: 1000 }, // Length | 265 | SUPPORT: { min: 3, max: 1000 }, // Length |
266 | IMAGE: { | 266 | IMAGE: { |
267 | EXTNAME: [ '.jpg', '.jpeg' ], | 267 | EXTNAME: [ '.png', '.jpg', '.jpeg', '.webp' ], |
268 | FILE_SIZE: { | 268 | FILE_SIZE: { |
269 | max: 2 * 1024 * 1024 // 2MB | 269 | max: 2 * 1024 * 1024 // 2MB |
270 | } | 270 | } |
@@ -298,7 +298,7 @@ const CONSTRAINTS_FIELDS = { | |||
298 | PRIVATE_KEY: { min: 10, max: 5000 }, // Length | 298 | PRIVATE_KEY: { min: 10, max: 5000 }, // Length |
299 | URL: { min: 3, max: 2000 }, // Length | 299 | URL: { min: 3, max: 2000 }, // Length |
300 | AVATAR: { | 300 | AVATAR: { |
301 | EXTNAME: [ '.png', '.jpeg', '.jpg', '.gif' ], | 301 | EXTNAME: [ '.png', '.jpeg', '.jpg', '.gif', '.webp' ], |
302 | FILE_SIZE: { | 302 | FILE_SIZE: { |
303 | max: 2 * 1024 * 1024 // 2MB | 303 | max: 2 * 1024 * 1024 // 2MB |
304 | } | 304 | } |