add CORS origins

This commit is contained in:
hueso committed 2026-10-29 20:25:43 -03:00
1 parent 25cca2e2df
commit 00d602cc38
1 file changed
+1 -1
+1 -1
View File
@@ -18,7 +18,7 @@ const primus = new Primus(config.primus, (...args) => log.info(...args));
const cache = new ProofCache();
const app = express();
app.use(cors());
app.use(cors({ origin: /^https?:\/\/(([a-z0-9-]+\.)*demo\.)?p2pix\.co$/ }));
app.use(express.json());
/** Only what the caller actually sent; empty sections stay out of the line. */
const received = (req: Request): Record<string, unknown> =>