mirror of
https://github.com/zoriya/flood.git
synced 2026-06-07 04:15:06 +00:00
server: torrents: properly catch errors of multiple awaits in /details
This commit is contained in:
@@ -632,6 +632,8 @@ router.get('/:hash/details', async (req, res) => {
|
||||
const peers = req.services?.clientGatewayService?.getTorrentPeers(req.params.hash);
|
||||
const trackers = req.services?.clientGatewayService?.getTorrentTrackers(req.params.hash);
|
||||
|
||||
await Promise.all([contents, peers, trackers]);
|
||||
|
||||
callback({
|
||||
contents: await contents,
|
||||
peers: await peers,
|
||||
|
||||
Reference in New Issue
Block a user