mirror of
https://github.com/ajayyy/SponsorBlock.git
synced 2025-12-07 20:17:05 +03:00
Remove redundant code.
This commit is contained in:
7
utils.js
7
utils.js
@@ -55,13 +55,6 @@ function localizeHtmlPage() {
|
|||||||
|
|
||||||
let localizedMessage = getLocalizedMessage(obj.innerHTML.toString());
|
let localizedMessage = getLocalizedMessage(obj.innerHTML.toString());
|
||||||
if (localizedMessage) obj.innerHTML = localizedMessage;
|
if (localizedMessage) obj.innerHTML = localizedMessage;
|
||||||
|
|
||||||
// Try on each attribute
|
|
||||||
let attributes = obj.getAttributeNames();
|
|
||||||
for (const attribute of attributes) {
|
|
||||||
localizedMessage = getLocalizedMessage(obj.getAttribute(attribute).toString());
|
|
||||||
if (localizedMessage) obj.setAttribute(attribute) = localizedMessage;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user