Skip to content

Commit a3ce811

Browse files
committed
Merge branch 'feat/images-api'
2 parents 7f0858a + c572abc commit a3ce811

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

dextools-api/index.js

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,14 @@ app.use(helmet());
2626
app.use(morgan("dev"));
2727
app.use(compression());
2828
app.use(express.json());
29-
app.use("/public", express.static(path.join(__dirname, "public")));
29+
app.use(
30+
"/public",
31+
express.static(path.join(__dirname, "public"), {
32+
setHeaders: (res, filePath) => {
33+
res.setHeader("Access-Control-Allow-Origin", "*");
34+
},
35+
})
36+
);
3037

3138
const asyncHandler = (fn) => async (req, res, next) => {
3239
try {

0 commit comments

Comments
 (0)