Browse Source

优化 util.match.js

pull/303/head
王良 7 months ago
parent
commit
b0f6a9afaf
  1. 3
      packages/mitmproxy/src/utils/util.match.js

3
packages/mitmproxy/src/utils/util.match.js

@ -6,6 +6,9 @@ function isMatched (url, regexp) {
}
function domainRegexply (target) {
if (target === '.*') {
return '^.*$'
}
return '^' + target.replace(/\./g, '\\.').replace(/\*/g, '.*') + '$'
}

Loading…
Cancel
Save