Minor fixes.

This commit is contained in:
Julien Fontanet 2014-01-29 17:00:25 +01:00
parent 028e950c81
commit 7c4e7eb225
2 changed files with 5 additions and 5 deletions

View File

@ -185,7 +185,7 @@ $watch = (collection, {
$each keys, (key) -> collection.on "key=#{key}", processOne
# Handles existing items.
process 'enter', collection.getRaw keys
process 'enter', (collection.getRaw keys, true)
else if not $_.isEmpty rules
# Matching is done the rules.

View File

@ -98,13 +98,13 @@ describe 'Helper', ->
'sum.bar': null
}
$expect(collecter.get 'sum.foo').to.equal 1
$expect(collecter.get 'sum.bar').to.equal 2
$expect(collection.get 'sum.foo').to.equal 1
$expect(collection.get 'sum.bar').to.equal 2
collection.remove 'bar'
$expect(collecter.get 'sum.foo').to.equal 1
$expect(collecter.get 'sum.bar').to.equal 0
$expect(collection.get 'sum.foo').to.equal 1
$expect(collection.get 'sum.bar').to.equal 0
it 'with single rule', ->
collection.set {