Fixed a regex bug for all services #76

This commit is contained in:
ManeraKai 2022-03-01 18:50:40 +03:00
parent 253d0622b2
commit 96a04b66f7
No known key found for this signature in database
GPG Key ID: 5ABC31FFD562E337
5 changed files with 16 additions and 16 deletions

View File

@ -1,7 +1,7 @@
window.browser = window.browser || window.chrome;
import commonHelper from './common.js'
const targets = /https?:\/\/(((www|maps)\.)?(google\.).*(\/maps)|maps\.(google\.).*)/;
const targets = /^https?:\/\/(((www|maps)\.)?(google\.).*(\/maps)|maps\.(google\.).*)/;
let redirects = {
"normal": [
"https://openstreetmap.org"

View File

@ -3,8 +3,8 @@ window.browser = window.browser || window.chrome;
import commonHelper from './common.js'
const targets = [
/https?:\/\/(www\.|maps\.|search\.|)google\.com(\...|)(\/search\?..*|\/$)/,
// /https?:\/\/yandex\.com(\...|)(\/search\/..*|\/$)/,
/^https?:\/\/(www\.|maps\.|search\.|)google\.com(\...|)(\/search\?..*|\/$)/,
// /^https?:\/\/yandex\.com(\...|)(\/search\/..*|\/$)/,
];
let redirects = {
"searx": {

View File

@ -3,12 +3,12 @@ window.browser = window.browser || window.chrome;
import commonHelper from './common.js'
const targets = [
/https?:\/\/twitter\.com/,
/https?:\/\/www\.twitter\.com/,
/https?:\/\/mobile\.twitter\.com/,
/https?:\/\/pbs\.twimg\.com/,
/https?:\/\/video\.twimg\.com/,
/https?:\/\/platform\.twitter\.com\/embed/
/^https?:\/\/twitter\.com/,
/^https?:\/\/www\.twitter\.com/,
/^https?:\/\/mobile\.twitter\.com/,
/^https?:\/\/pbs\.twimg\.com/,
/^https?:\/\/video\.twimg\.com/,
/^https?:\/\/platform\.twitter\.com\/embed/
];
let redirects = {

View File

@ -5,16 +5,16 @@ import commonHelper from '../common.js'
window.browser = window.browser || window.chrome;
const targets = [
/https?:\/\/(www\.|music\.|m\.|)youtube\.com(\/.*|$)/,
/^https?:\/\/(www\.|music\.|m\.|)youtube\.com(\/.*|$)/,
/https?:\/\/img\.youtube\.com\/vi\/.*\/..*/, // https://stackoverflow.com/questions/2068344/how-do-i-get-a-youtube-video-thumbnail-from-the-youtube-api
/https?:\/\/(i|s)\.ytimg\.com\/vi\/.*\/..*/,
/^https?:\/\/img\.youtube\.com\/vi\/.*\/..*/, // https://stackoverflow.com/questions/2068344/how-do-i-get-a-youtube-video-thumbnail-from-the-youtube-api
/^https?:\/\/(i|s)\.ytimg\.com\/vi\/.*\/..*/,
/https?:\/\/(www\.|music\.|)youtube\.com\/watch\?v\=..*/,
/^https?:\/\/(www\.|music\.|)youtube\.com\/watch\?v\=..*/,
/https?:\/\/youtu\.be\/..*/,
/^https?:\/\/youtu\.be\/..*/,
/https?:\/\/(www\.|)(youtube|youtube-nocookie)\.com\/embed\/..*/,
/^https?:\/\/(www\.|)(youtube|youtube-nocookie)\.com\/embed\/..*/,
];
let redirects = {
"invidious": {

View File

@ -5,7 +5,7 @@ import commonHelper from './common.js'
window.browser = window.browser || window.chrome;
const targets = [
/https?:\/\/music\.youtube\.com(\/.*|$)/,
/^https?:\/\/music\.youtube\.com(\/.*|$)/,
];
let redirects = {
"beatbump": {