don't need partial ability when deferring config calling
This commit is contained in:
parent
a87e2a1414
commit
18dcfce5e2
1 changed files with 5 additions and 5 deletions
10
mithril.js
10
mithril.js
|
|
@ -199,12 +199,12 @@ Mithril = m = new function app(window, undefined) {
|
||||||
var context = cached.configContext = cached.configContext || {}
|
var context = cached.configContext = cached.configContext || {}
|
||||||
|
|
||||||
// bind
|
// bind
|
||||||
configs.push((function (data, node, isNew, context, cached) {
|
var callback = function(data, args) {
|
||||||
var args = [node, !isNew, context, cached]
|
return function() {
|
||||||
return function () {
|
return data.attrs["config"].apply(data, args)
|
||||||
return data.attrs["config"].apply(data, args.concat(Array.prototype.slice.call(arguments, 0)))
|
|
||||||
}
|
}
|
||||||
})(data, node, isNew, context, cached))
|
}
|
||||||
|
configs.push(callback(data, [node, !isNew, context, cached]))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (typeof dataType != "function") {
|
else if (typeof dataType != "function") {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue