mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2026-02-14 22:35:47 +01:00
Prevent stylesheets from being appended to the list more than once.
This commit is contained in:
@@ -107,12 +107,13 @@ const Styles = Module("Styles", {
|
||||
sheet.filter = filter;
|
||||
sheet.css = String(css);
|
||||
}
|
||||
else
|
||||
else {
|
||||
sheet = Sheet(name, this._id++, filter.filter(util.identity), String(css), system, agent);
|
||||
sheets.push(sheet);
|
||||
}
|
||||
|
||||
if (!lazy)
|
||||
sheet.enabled = true;
|
||||
sheets.push(sheet);
|
||||
|
||||
if (name)
|
||||
names[name] = sheet;
|
||||
|
||||
Reference in New Issue
Block a user