Created
April 18, 2018 13:44
-
-
Save robertherdzik/af077d99b9660b0979f5a30eb1b619e5 to your computer and use it in GitHub Desktop.
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
extension Optional where Wrapped == String { | |
func valueOrEmptyString() -> String { | |
guard let value = self else { return "" } | |
return value | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment