Commit dbf20052 authored by JC Brand's avatar JC Brand

console can be defined higher up

parent d38af7ed
......@@ -11,8 +11,10 @@
// AMD/global registrations
(function (root, factory) {
if (console===undefined || console.log===undefined) {
console = { log: function () {}, error: function () {} };
}
if (typeof define === 'function' && define.amd) {
require.config({
// paths: {
// "patterns": "Libraries/Patterns"
......@@ -58,10 +60,6 @@
evaluate : /\{\[([\s\S]+?)\]\}/g,
interpolate : /\{\{([\s\S]+?)\}\}/g
};
if (console===undefined || console.log===undefined) {
console = { log: function () {}, error: function () {} };
}
return factory(jQuery, store, _, console);
}
);
......@@ -72,9 +70,6 @@
evaluate : /\{\[([\s\S]+?)\]\}/g,
interpolate : /\{\{([\s\S]+?)\}\}/g
};
if (console===undefined || console.log===undefined) {
console = { log: function () {}, error: function () {} };
}
root.xmppchat = factory(jQuery, store, _, console || {log: function(){}});
}
}(this, function ($, store, _, console) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment