diff --git a/lib/client/load.js b/lib/client/load.js index 5170a728..0f84c00f 100644 --- a/lib/client/load.js +++ b/lib/client/load.js @@ -3,12 +3,9 @@ var DOMProto = Object.getPrototypeOf(DOM); - DOMProto.load = new LoaderProto(Util, DOM); + DOMProto.load = new LoaderProto(Util, DOM.Images, DOM.Events); - function LoaderProto(Util, DOM) { - var Images = DOM.Images, - Events = DOM.Events; - + function LoaderProto(Util, Images, Events) { /** * Функция создаёт элемент и загружает файл с src. * @@ -72,7 +69,7 @@ if (!p.id && p.src) p.id = load.getIdBySrc(p.src); - element = DOM.getById(p.id); + element = document.getElementById(p.id); if (element) { Util.exec(func);