fix corner case in inline (#3778)

fixes #3777
This commit is contained in:
Alex Lam S.L
2020-04-11 12:54:26 +01:00
committed by GitHub
parent c810ecd081
commit 903a5df9a5
3 changed files with 63 additions and 11 deletions

View File

@@ -217,6 +217,12 @@ Dictionary.prototype = {
return this;
},
has: function(key) { return ("$" + key) in this._values },
all: function(predicate) {
for (var i in this._values)
if (!predicate(this._values[i], i.substr(1)))
return false;
return true;
},
each: function(f) {
for (var i in this._values)
f(this._values[i], i.substr(1));