Avoid adding CSS files again if they're already in the header

This commit is contained in:
Nathan Gray 2013-11-19 23:22:33 +00:00
parent 3425b22074
commit 089144d986

View File

@ -105,10 +105,13 @@ egw.extend('files', egw.MODULE_WND_LOCAL, function(_app, _wnd)
// Get the head node and append the newly created "link" node // Get the head node and append the newly created "link" node
// to it. // to it.
var head = _wnd.document.getElementsByTagName('head')[0]; var head = _wnd.document.getElementsByTagName('head')[0];
if(jQuery('link[href="'+_cssFile+'"]',head).length == 0)
{
head.appendChild(cssnode); head.appendChild(cssnode);
} }
} }
} }
}
}); });