From 5a210c61b2deff8cfe54b6e796de4fbc7095ba1e Mon Sep 17 00:00:00 2001 From: Federico Date: Sun, 12 Jul 2026 00:18:27 +0800 Subject: [PATCH] Update 404 test --- index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/index.ts b/index.ts index 06a0547..0fe5963 100644 --- a/index.ts +++ b/index.ts @@ -57,7 +57,7 @@ TEST: addTests('__urls_that_dont_match__', [ 'https://github.com/orgs/community/discussions/new/choose', ]); -export const is404 = (): boolean => /^(Page|File) not found · GitHub/.test(document.title); // #98; When logged out, it starts with "File" +export const is404 = (): boolean => /^(Page|File) not found(?: · GitHub|$)/.test(document.title); export const is500 = (): boolean => document.title === 'Server Error · GitHub' || document.title === 'Unicorn! · GitHub' || document.title === '504 Gateway Time-out';