(function(window, document, undefined) {
+ 'use strict';
+
/* Object.assign polyfill for IE */
if (typeof Object.assign !== 'function') {
Object.defineProperty(Object, 'assign', {
* HTTP Request helper
*/
- Headers = Class.extend({
+ var Headers = Class.extend({
__name__: 'LuCI.XHR.Headers',
__init__: function(xhr) {
var hdrs = this.headers = {};
}
});
- Response = Class.extend({
+ var Response = Class.extend({
__name__: 'LuCI.XHR.Response',
__init__: function(xhr, url, duration) {
this.ok = (xhr.status >= 200 && xhr.status <= 299);
}
});
- Request = Class.singleton({
+ var Request = Class.singleton({
__name__: 'LuCI.Request',
interceptors: [],
originalCBIInit = null,
classes = {};
- LuCI = Class.extend({
+ var LuCI = Class.extend({
__name__: 'LuCI',
__init__: function(env) {
/* load dependencies and instantiate class */
return Promise.all(depends).then(function(instances) {
+ var _factory, _class;
+
try {
_factory = eval(
'(function(window, document, L%s) { %s })\n\n//# sourceURL=%s\n'
})
});
- XHR = Class.extend({
+ var XHR = Class.extend({
__name__: 'LuCI.XHR',
__init__: function() {
if (window.console && console.debug)