Skip to content

Commit

Permalink
pattern bug fix; minor text changes in patterns screen (I dont like t…
Browse files Browse the repository at this point in the history
…he layout, though); version bump
  • Loading branch information
ericjung committed Sep 26, 2019
1 parent 913c5a9 commit b5e1a06
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 7 deletions.
3 changes: 2 additions & 1 deletion src/_locales/en/messages.json
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,8 @@
"down": { "message": "move down" },

"disabled": { "message": "Disabled" },
"active": { "message": "Enabled for patterns and priorities mode" },
"active": { "message": "Enabled" },
"activeNote": { "message": "Enabling/Disabling a pattern here only affects FoxyProxy when using 'Enabled Proxies By Patterns and Order'"},


"name": { "message": "Name" },
Expand Down
7 changes: 6 additions & 1 deletion src/about.html
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,12 @@ <h3>Support Me</h3>


<h3>Release Notes for Recent Releases</h3>

<h4>Version 7.1</h4>
<ul>
<li>Patterns bugfix for bug introduced in 7.0</li>
<li>Text changes in patterns window</li>
</ul>

<h4>Version 7.0</h4>
<ul>

Expand Down
2 changes: 1 addition & 1 deletion src/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

"name": "__MSG_extensionName__",
"description": "__MSG_extensionDescription__",
"version": "7.0",
"version": "7.1",
"default_locale": "en",
"homepage_url": "https://getfoxyproxy.org/",
"author": "Eric Jung",
Expand Down
6 changes: 4 additions & 2 deletions src/patterns.html
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,9 @@ <h3 data-i18n="errorWas"></h3>

<!-- main -->
<div class="prime main">
<div style="text-align: right;">
<strong><span style="margin-right: 15rem" data-i18n="activeNote"></span></strong>
<br>
<div>
<a href="/pattern-help.html" target="_blank"><span data-i18n="patternHelp"></span> <i class="fa fa-question-circle"></i></a> |
<a href="/pattern-tester.html" target="_blank"><span data-i18n="patternTester"></span> <i class="fa fa-flask"></i></a>
</div>
Expand Down Expand Up @@ -114,7 +116,7 @@ <h3 data-i18n="blackPatterns"></h3>
<thead>
<tr>
<th data-i18n="name"></th><th data-i18n="pattern"></th><th data-i18n="type"></th>
<th>HTTP/s</th><th data-i18n="active"></th><th></th>
<th>HTTP/s</th><th data-i18n="active"></th><th></th>
</tr>
</thead>

Expand Down
4 changes: 2 additions & 2 deletions src/scripts/pac.js
Original file line number Diff line number Diff line change
Expand Up @@ -49,14 +49,14 @@ function findProxyMatch(url) {

// Check black patterns first
const blackMatch = proxy.blackPatterns.find(item =>
item.protocols === schemeSet.all || item.protocols === schemeSet[scheme] &&
(item.protocols === schemeSet.all || item.protocols === schemeSet[scheme]) &&
new RegExp(item['regExp'], 'i').test(hostPort));

//if (blackMatch) { return null; } // found a blacklist match, end here, use direct, no proxy
if (blackMatch) { continue; } // if blacklist matched move to the next proxy

const whiteMatch = proxy.whitePatterns.find(item =>
item.protocols === schemeSet.all || item.protocols === schemeSet[scheme] &&
(item.protocols === schemeSet.all || item.protocols === schemeSet[scheme]) &&
new RegExp(item['regExp'], 'i').test(hostPort));

if (whiteMatch) { return {proxy, pattern: whiteMatch}; } // found a whitelist match, end here
Expand Down

0 comments on commit b5e1a06

Please sign in to comment.