Implement method_missing on the map annotations to try and return a parameter named what the user asked for.

This commit is contained in:
Mark Rickert
2013-09-13 05:33:52 -04:00
parent bc6e2e8aa5
commit 36c59f52c2

View File

@@ -52,5 +52,13 @@ module ProMotion
@params
end
def method_missing(meth, *args)
if @params[meth.to_sym]
@params[meth.to_sym]
else
PM.logger.warn "The annotation parameter \"#{meth}\" does not exist on this pin."
end
end
end
end