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