[Add] Remove obsolete variable reference

The cache has been externalized to allow writing to it
upon domain object instantiation.
This commit is contained in:
Victor Woeltjen 2016-03-21 10:31:38 -07:00
parent 3fe41575bd
commit 9c9db3c24f

View File

@ -59,7 +59,7 @@ define(
// We update in-place to ensure there is only ever one instance
// of any given model exposed by the modelService as a whole.
function updateModel(id, model) {
var oldModel = cache[id];
var oldModel = cacheService.get(id);
// Same object instance is a possibility, so don't copy
if (oldModel === model) {
@ -108,7 +108,7 @@ define(
}
// Otherwise, just expose the cache directly
return fastPromise(cache);
return fastPromise(cacheService.all());
};
return CachingModelDecorator;