Skip to content

Commit ffcbda7

Browse files
style: auto format
1 parent b60e197 commit ffcbda7

File tree

1 file changed

+18
-16
lines changed

1 file changed

+18
-16
lines changed

netlify/edge-functions/rsshub.js

Lines changed: 18 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -9,24 +9,26 @@ const require = createRequire(import.meta.url);
99
const rsshub = require('../../app.js');
1010

1111
export default async (req, context) => {
12-
return new Promise((resolve) => {
13-
const res = {
14-
writeHead: (status, headers) => {
15-
res.status = status;
16-
res.headers = headers;
17-
},
18-
end: (body) => {
19-
resolve(new Response(body, {
20-
status: res.status || 200,
21-
headers: res.headers || {}
22-
}));
23-
}
24-
};
12+
return new Promise((resolve) => {
13+
const res = {
14+
writeHead: (status, headers) => {
15+
res.status = status;
16+
res.headers = headers;
17+
},
18+
end: (body) => {
19+
resolve(
20+
new Response(body, {
21+
status: res.status || 200,
22+
headers: res.headers || {},
23+
})
24+
);
25+
},
26+
};
2527

26-
rsshub(req, res);
27-
});
28+
rsshub(req, res);
29+
});
2830
};
2931

3032
export const config = {
31-
path: "/*"
33+
path: '/*',
3234
};

0 commit comments

Comments
 (0)