Commit 8a07c6e3 authored by Romain Courteaud's avatar Romain Courteaud

[erp5_gadget_interface_validator] Simplify

parent e1708acd
/*jslint nomen: true, indent: 2, maxerr: 30, maxlen: 80 */
/*global DOMParser, document, rJS, renderJS, RSVP, window,
/*global DOMParser, document, rJS, RSVP, window,
jIO*/
(function (window, rJS, RSVP, DOMParser, renderJS, jIO) {
(function (window, rJS, RSVP, DOMParser, jIO) {
"use strict";
function fetchAppcacheData(appcache_url) {
......@@ -75,8 +75,8 @@
if (element.href !== null &&
element.rel === "http://www.renderjs.org/rel/interface") {
interface_list.push(
renderJS.getAbsoluteURL(element.getAttribute("href"),
window.location.href)
rJS.getAbsoluteURL(element.getAttribute("href"),
window.location.href)
);
}
}
......@@ -279,9 +279,7 @@
return interface_gadget.declareGadget(gadget_url, {
scope: gadget_url
})
.push(function () {
return interface_gadget.getDeclaredGadget(gadget_url);
}, function (error) {
.push(undefined, function (error) {
var message = "Error with loading the gadget.\n";
error.message = message + error.message;
throw error;
......@@ -590,4 +588,4 @@
});
});
}(window, rJS, RSVP, DOMParser, renderJS, jIO));
\ No newline at end of file
}(window, rJS, RSVP, DOMParser, jIO));
\ No newline at end of file
......@@ -230,7 +230,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>968.15691.27792.32785</string> </value>
<value> <string>968.15707.16175.19985</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -248,7 +248,7 @@
</tuple>
<state>
<tuple>
<float>1529077770.12</float>
<float>1529078216.58</float>
<string>UTC</string>
</tuple>
</state>
......
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