Commit 7996dfca authored by Tristan Cavelier's avatar Tristan Cavelier

Updating Local Storage

parent 9d672f03
......@@ -136,8 +136,8 @@ var newLocalStorage = function ( spec, my ) {
doc.content = command.getContent();
}
LocalOrCookieStorage.setItem(path, doc);
that.done();
}, 100);
that.success ();
});
}; // end saveDocument
/**
......@@ -159,16 +159,16 @@ var newLocalStorage = function ( spec, my ) {
'jio/local/'+priv.username+'/'+
priv.applicationname+'/'+command.getPath());
if (!doc) {
that.fail({status:404,statusText:'Not Found.',
message:'Document "'+ command.getPath() +
'" not found in localStorage.'});
that.error ({status:404,statusText:'Not Found.',
message:'Document "'+ command.getPath() +
'" not found in localStorage.'});
} else {
if (command.getOption('metadata_only')) {
delete doc.content;
}
that.done(doc);
that.success (doc);
}
}, 100);
});
}; // end loadDocument
/**
......@@ -205,8 +205,8 @@ var newLocalStorage = function ( spec, my ) {
}
}
}
that.done(new_array);
}, 100);
that.success (new_array);
});
}; // end getDocumentList
/**
......@@ -223,8 +223,8 @@ var newLocalStorage = function ( spec, my ) {
// deleting
LocalOrCookieStorage.deleteItem(path);
priv.removeFileName(command.getPath());
that.done();
}, 100);
that.success ();
});
};
return that;
};
......
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