X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=server.ts;h=fffb8038f3475a0a1ff6d55f2bd1b3b8d82831de;hb=106e68cfff2573af5262e282101358d7fb926184;hp=5511c5435856fec72698f20295fa35e754d44267;hpb=8afc19a6121569da054462c7cb351a3f13030a32;p=github%2FChocobozzz%2FPeerTube.git diff --git a/server.ts b/server.ts index 5511c5435..fffb8038f 100644 --- a/server.ts +++ b/server.ts @@ -90,7 +90,8 @@ if (isTestInstance()) { // These routes have already cors if ( req.path.indexOf(STATIC_PATHS.TORRENTS) === -1 && - req.path.indexOf(STATIC_PATHS.WEBSEED) === -1 + req.path.indexOf(STATIC_PATHS.WEBSEED) === -1 && + req.path.startsWith('/api/') === false ) { return (cors({ origin: '*',