Refactor incomingData

This commit is contained in:
Jean-Baptiste Dominguez 2018-08-31 18:37:04 +09:00
commit ddd867092c
6 changed files with 90 additions and 55 deletions

View file

@ -29,13 +29,17 @@ angular
map: map,
pop: pop,
push: push,
isEmpty: isEmpty
};
return service;
function init(params) {
clear();
push(params);
if (params) {
push(params);
}
}
function clear() {
@ -94,6 +98,10 @@ angular
clearCurrent();
map(params);
};
function isEmpty() {
return service.previousStates.length == 0;
};
};
})();