Commit 80604c9e authored by Sven Franck's avatar Sven Franck

Safari: test parsing stored JSON definition

parent 00ffe8ee
...@@ -3150,8 +3150,6 @@ ...@@ -3150,8 +3150,6 @@
* @return {object} object Parsed object * @return {object} object Parsed object
*/ */
util.parseIfNeeded = function (data) { util.parseIfNeeded = function (data) {
console.log("we get")
console.log(data)
if (typeof data === "string") { if (typeof data === "string") {
return JSON.parse(data); return JSON.parse(data);
} }
...@@ -4350,16 +4348,14 @@ ...@@ -4350,16 +4348,14 @@
* @param {object} response object containing data (jio.util.ajax response) * @param {object} response object containing data (jio.util.ajax response)
* @return {object} promise object * @return {object} promise object
*/ */
init.setupStorages = function (response) { init.setupStorages = function (e) {
var i, var i,
store, store,
promises = [], promises = [],
config = response.target.response; config = util.parseIfNeeded(e.target.response);
if (typeof config === "string") {
config = JSON.parse(config);
}
console.log(config)
console.log(config.length)
for (i = 0; i < config.length; i += 1) { for (i = 0; i < config.length; i += 1) {
store = config[i].definition; store = config[i].definition;
......
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