mirror of
https://github.com/ajayyy/SponsorBlock.git
synced 2025-12-24 08:28:31 +03:00
remove port from invidious domain as it is not needed
This commit is contained in:
@@ -445,7 +445,12 @@ function invidiousInstanceAddInit(element: HTMLElement, option: string) {
|
||||
let instanceList = Config.config[option];
|
||||
if (!instanceList) instanceList = [];
|
||||
|
||||
instanceList.push(textBox.value.trim().toLowerCase());
|
||||
let domain = textBox.value.trim().toLowerCase();
|
||||
if (domain.includes(":")) {
|
||||
domain = domain.split(":")[0];
|
||||
}
|
||||
|
||||
instanceList.push(domain);
|
||||
|
||||
Config.config[option] = instanceList;
|
||||
|
||||
|
||||
@@ -240,8 +240,6 @@ export default class Utils {
|
||||
for (const url of domains) {
|
||||
permissionRegex.push("https://*." + url + "/*");
|
||||
permissionRegex.push("http://*." + url + "/*");
|
||||
permissionRegex.push("https://" + url + "/*");
|
||||
permissionRegex.push("http://" + url + "/*");
|
||||
}
|
||||
|
||||
return permissionRegex;
|
||||
|
||||
Reference in New Issue
Block a user