##// END OF EJS Templates
templater: do dict lookup over a wrapped object...
Yuya Nishihara -
r38258:c2456a77 default
parent child Browse files
Show More
@@ -261,7 +261,7 b' def get(context, mapping, args):'
261 # i18n: "get" is a keyword
261 # i18n: "get" is a keyword
262 raise error.ParseError(_("get() expects two arguments"))
262 raise error.ParseError(_("get() expects two arguments"))
263
263
264 dictarg = evalfuncarg(context, mapping, args[0])
264 dictarg = evalwrapped(context, mapping, args[0])
265 if not util.safehasattr(dictarg, 'get'):
265 if not util.safehasattr(dictarg, 'get'):
266 # i18n: "get" is a keyword
266 # i18n: "get" is a keyword
267 raise error.ParseError(_("get() expects a dict as first argument"))
267 raise error.ParseError(_("get() expects a dict as first argument"))
@@ -662,7 +662,7 b' def runmap(context, mapping, data):'
662
662
663 def runmember(context, mapping, data):
663 def runmember(context, mapping, data):
664 darg, memb = data
664 darg, memb = data
665 d = evalrawexp(context, mapping, darg)
665 d = evalwrapped(context, mapping, darg)
666 if util.safehasattr(d, 'tomap'):
666 if util.safehasattr(d, 'tomap'):
667 lm = context.overlaymap(mapping, d.tomap())
667 lm = context.overlaymap(mapping, d.tomap())
668 return runsymbol(context, lm, memb)
668 return runsymbol(context, lm, memb)
General Comments 0
You need to be logged in to leave comments. Login now