diff options
author | 2020-05-30 14:47:23 +0200 | |
---|---|---|
committer | 2020-05-30 14:47:23 +0200 | |
commit | 2a81048d4336b7a307d8b712a6362e9c34f03013 (patch) | |
tree | 3b8fe21eb8ff5fd933f31774e52fe44d91c25565 /source/features/preview-hidden-comments.tsx | |
parent | 7589633720493550e359468ffdb4294858b74646 (diff) | |
download | refined-github-2a81048d4336b7a307d8b712a6362e9c34f03013.tar.gz refined-github-2a81048d4336b7a307d8b712a6362e9c34f03013.tar.zst refined-github-2a81048d4336b7a307d8b712a6362e9c34f03013.zip |
Meta: config and build cleanup (#3157)
Diffstat (limited to 'source/features/preview-hidden-comments.tsx')
-rw-r--r-- | source/features/preview-hidden-comments.tsx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source/features/preview-hidden-comments.tsx b/source/features/preview-hidden-comments.tsx index ae5bbf5e..dcb49e83 100644 --- a/source/features/preview-hidden-comments.tsx +++ b/source/features/preview-hidden-comments.tsx @@ -5,7 +5,7 @@ import * as pageDetect from 'github-url-detection'; import features from '.'; -const allowedReasons = ['resolved', 'outdated', 'off-topic']; +const allowedReasons = new Set(['resolved', 'outdated', 'off-topic']); const capitalize = (text: string): string => text.charAt(0).toUpperCase() + text.slice(1); @@ -24,7 +24,7 @@ const init = (): void => { `, details)!; const reason = /was marked as ([^.]+)/.exec(header.textContent!)?.[1] ?? ''; - if (!allowedReasons.includes(reason)) { + if (!allowedReasons.has(reason)) { continue; } |