We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 2543b8c commit f53b8f2Copy full SHA for f53b8f2
index.js
@@ -3,10 +3,10 @@
3
const Hashids = require('hashids/cjs');
4
const NODE_ENV = process.env.NODE_ENV;
5
const isProduction = (NODE_ENV === 'production');
6
-const IGNORE_AUTH_PATH_REGEX = process.env.IGNORE_AUTH_PATH_REGEX || /(web)/;
+const IGNORE_AUTH_PATH_REGEX = process.env.IGNORE_AUTH_PATH_REGEX || '';
7
8
function isIgnoredPath(path) {
9
- return path.search(IGNORE_AUTH_PATH_REGEX) >= 0;
+ return IGNORE_AUTH_PATH_REGEX !== '' && path.search(IGNORE_AUTH_PATH_REGEX) >= 0;
10
}
11
12
function genHashId(idHashids, id = 141236) {
0 commit comments