cleanup sentDate keys in device storage

This commit is contained in:
Tankred Hase 2013-09-26 16:30:34 +02:00
parent 2b966c1132
commit 7fe8755b99
3 changed files with 9 additions and 4 deletions

View File

@ -7,8 +7,7 @@
define(function(require) {
'use strict';
var util = require('cryptoLib/util'),
jsonDao = require('js/dao/lawnchair-dao');
var jsonDao = require('js/dao/lawnchair-dao');
var DeviceStorageDAO = function() {
@ -24,7 +23,7 @@ define(function(require) {
* @param type [String] The type of item to be persisted e.g. 'email'
*/
DeviceStorageDAO.prototype.storeList = function(list, type, callback) {
var date, key, items = [];
var key, items = [];
// nothing to store
if (!list || list.length === 0) {
@ -46,7 +45,6 @@ define(function(require) {
if (i.uid) {
key = type + '_' + i.uid;
} else if (i.sentDate && i.id) {
date = util.parseDate(i.sentDate);
key = type + '_' + i.sentDate + '_' + i.id;
} else if (i.id) {
key = type + '_' + i.id;

6
src/lib/moment/moment.min.js vendored Normal file

File diff suppressed because one or more lines are too long

View File

@ -19,6 +19,7 @@
angular: 'angular/angular.min',
angularRoute: 'angular/angular-route.min',
angularTouch: 'angular/angular-touch.min',
moment: 'moment/moment.min',
uuid: 'uuid/uuid'
},
shim: {