lib/ixtlan/babel/context.rb in ixtlan-babel-0.3.4 vs lib/ixtlan/babel/context.rb in ixtlan-babel-0.3.5
- old
+ new
@@ -53,10 +53,14 @@
def array?
@include.is_a?( Array )
end
def []( key )
- self.class.new( @include.is_a?( Array ) ? {} : @include[ key ] )
+ if @include.include?( key )
+ self.class.new( @include.is_a?( Array ) ? {} : @include[ key ] )
+ else
+ self.class.new( @methods.is_a?( Array ) ? {} : @methods[ key ] )
+ end
end
end
end
end