Created
April 8, 2014 15:17
-
-
Save saturnflyer/10140954 to your computer and use it in GitHub Desktop.
overriding presenter with
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def with_conditions(method_name, computed_value) | |
if method_name.to_s == 'address' && !computed_value.nil? | |
address.renderable? | |
else | |
super | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment