aboutsummaryrefslogtreecommitdiffstats
path: root/example/personalLog
diff options
context:
space:
mode:
authorMisko Hevery2011-11-03 21:14:04 -0700
committerMisko Hevery2011-11-14 20:31:14 -0800
commitc27aba4354c69c4a67fab587a59a8079cc9edc91 (patch)
tree7ea9f170c197dddcfb8014fc85437523090d18a4 /example/personalLog
parentdd9151e522220b438074e55c72f47ed2a8da9933 (diff)
downloadangular.js-c27aba4354c69c4a67fab587a59a8079cc9edc91.tar.bz2
refactor(api): remove type augmentation
BREAK: - remove angular.[Object/Array/String/Function] - in templates [].$filter(predicate) and friends need to change to [] | filter:predicate
Diffstat (limited to 'example/personalLog')
-rw-r--r--example/personalLog/personalLog.js10
1 files changed, 8 insertions, 2 deletions
diff --git a/example/personalLog/personalLog.js b/example/personalLog/personalLog.js
index acaf371e..7be233cb 100644
--- a/example/personalLog/personalLog.js
+++ b/example/personalLog/personalLog.js
@@ -54,7 +54,13 @@ function LogCtrl($cookieStore) {
* @param {object} log The log to remove.
*/
this.rmLog = function(log) {
- angular.Array.remove(logs, log);
+ for ( var i = 0; i < logs.length; i++) {
+ if (log === logs[i]) {
+ logs.splice(i, 1);
+ break;
+ }
+ }
+
$cookieStore.put(LOGS, logs);
};
@@ -73,4 +79,4 @@ LogCtrl.$inject = ['$cookieStore'];
//export
example.personalLog.LogCtrl = LogCtrl;
-})(); \ No newline at end of file
+})();