Skip to content

Commit

Permalink
Rename entry to modifying
Browse files Browse the repository at this point in the history
In the function we have variables named existing and
entry, while both are entries. Renaming both to
the adjectives makes more sense.
  • Loading branch information
nb committed Apr 17, 2013
1 parent 9888079 commit 39739c2
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions js/liveblog.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,16 +47,16 @@ window.liveblog = {};
collection.applyModifyingEntry(entry);
});
},
applyModifyingEntry: function(entry) {
var existing = this.get(entry.id);
applyModifyingEntry: function(modifying) {
var existing = this.get(modifying.id);
if (!existing) {
return;
}
if ('delete' === entry.type) {
if ('delete' === modifying.type) {
this.remove(existing);
}
if ('update' === entry.type) {
existing.set('html', entry.html);
if ('update' === modifying.type) {
existing.set('html', modifying.html);
}
}
});
Expand Down

0 comments on commit 39739c2

Please sign in to comment.