Created
April 8, 2019 09:25
-
-
Save NaiyaShah-BTC/b5ab4a92dd20ec6d0e813ce951fed29b to your computer and use it in GitHub Desktop.
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
# best | |
# Will return value of name or nil | |
properties.dig(:user, :profile, :name) | |
# Will return true or false | |
properties.dig(:user, :profile, :name).present? |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment