diff options
author | Chocobozzz <me@florianbigard.com> | 2019-07-16 14:52:24 +0200 |
---|---|---|
committer | Chocobozzz <chocobozzz@cpy.re> | 2019-07-24 10:58:16 +0200 |
commit | e0ce715a1ded6e84c877004dae3e354c8716fb06 (patch) | |
tree | c2a48af098e27fea2c2c6bb47b2daa68103c1a0e /server/controllers | |
parent | 89c344dba4ae2fca39cf636c3c6f09f31a339493 (diff) | |
download | PeerTube-e0ce715a1ded6e84c877004dae3e354c8716fb06.tar.gz PeerTube-e0ce715a1ded6e84c877004dae3e354c8716fb06.tar.zst PeerTube-e0ce715a1ded6e84c877004dae3e354c8716fb06.zip |
Check latest plugins version
Diffstat (limited to 'server/controllers')
-rw-r--r-- | server/controllers/api/plugins.ts | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/server/controllers/api/plugins.ts b/server/controllers/api/plugins.ts index 114cc49b6..bb410e891 100644 --- a/server/controllers/api/plugins.ts +++ b/server/controllers/api/plugins.ts | |||
@@ -180,5 +180,11 @@ async function listAvailablePlugins (req: express.Request, res: express.Response | |||
180 | 180 | ||
181 | const resultList = await listAvailablePluginsFromIndex(query) | 181 | const resultList = await listAvailablePluginsFromIndex(query) |
182 | 182 | ||
183 | if (!resultList) { | ||
184 | return res.status(503) | ||
185 | .json({ error: 'Plugin index unavailable. Please retry later' }) | ||
186 | .end() | ||
187 | } | ||
188 | |||
183 | return res.json(resultList) | 189 | return res.json(resultList) |
184 | } | 190 | } |