-
-
Save toreriklinnerud/215406 to your computer and use it in GitHub Desktop.
using graph, common method and present in our app, but not standard in ruby/rails
This file contains 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 build_message | |
message = PORTFOLIO_FIELDS.graph{|field, _| [field, send(field)] } | |
self.message = message.delete_if { |_, value| value.nil? } | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment