Skip to content

Commit 58af654

Browse files
committed
Add worker identification to 404 headers.
Also bumps build number.
1 parent 3e3c71f commit 58af654

3 files changed

Lines changed: 6 additions & 3 deletions

File tree

package-lock.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "cloudfinger",
3-
"version": "1.0.221212.1",
3+
"version": "1.0.221212.2",
44
"description": "webfinger cloudflare worker",
55
"scripts": {
66
"format": "prettier --write .",

src/controller.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,10 @@ export const finger = async (request: Request, env: any): Promise<Response> => {
6262
};
6363

6464
export const fourohfour = async (): Promise<Response> => {
65-
return new Response('NOT FOUND', { status: 404 });
65+
return new Response('NOT FOUND', {
66+
status: 404,
67+
headers: { worker: `'${name} ${version}'` },
68+
});
6669
};
6770

6871
export const status = async (request: Request, env: any): Promise<Response> => {

0 commit comments

Comments
 (0)