Revision 26459fb4
Added by koszko over 1 year ago
common/misc.js | ||
---|---|---|
85 | 85 |
* case of `file://' protocol). |
86 | 86 |
*/ |
87 | 87 |
#IF MOZILLA |
88 |
const priv_reg = /^moz-extension:\/\/|^about:|^file:\/\/[^?#]*\/([?#]|$)/; |
|
88 |
const priv_reg = /^moz-extension:\/\/|^about:|^view-source:|^file:\/\/[^?#]*\/([?#]|$)/;
|
|
89 | 89 |
#ELIF CHROMIUM |
90 |
const priv_reg = /^chrome(-extension)?:\/\/|^about:|^file:\/\/[^?#]*\/([?#]|$)/; |
|
90 |
const priv_reg = /^chrome(-extension)?:\/\/|^about:|^view-source:|^file:\/\/[^?#]*\/([?#]|$)/;
|
|
91 | 91 |
#ENDIF |
92 | 92 |
#EXPORT url => priv_reg.test(url) AS is_privileged_url |
Also available in: Unified diff
treat "view-source:" pages as privileged