You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Apr 12, 2024. It is now read-only.
but there is no test if it is really in the data, so if remove is called with something thats not inside the data nothing is deleted but the size is decreased.
see line:
https://github.com/angular/angular.js/blob/master/src/ng/cacheFactory.js#L227
there size-- is done but just before it we do:
delete data[key];
but there is no test if it is really in the data, so if remove is called with something thats not inside the data nothing is deleted but the size is decreased.
the put function does have a check:
if (!(key in data)) size++;
data[key] = value;
shouldn't remove not have a similar one?