Permalink
Browse files

Pass the 'view' as the first argument

  • Loading branch information...
1 parent 82f3ab9 commit dc5d6df2a6d0d65e9c4bbcf23433003ae6ac8101 Lloyd Watkin committed Jun 7, 2012
Showing with 2 additions and 1 deletion.
  1. +2 −1 src/template.coffee
View
@@ -28,7 +28,7 @@ ff = (proto, tags) -> # fill with tags
class Template extends EventEmitter
- constructor: (opts = {}, template) ->
+ constructor: (view, opts = {}, template) ->
# options
[template, opts] = [opts, {}] if typeof opts is 'function'
# defaults
@@ -53,6 +53,7 @@ class Template extends EventEmitter
# instantiate
@xml = new ExtendedBuilder opts
@xml.template = this
+ @xml.view = view
# override query
old_query = @xml.query
@xml.query = (type, tag, key) ->

0 comments on commit dc5d6df

Please sign in to comment.