Last active
December 16, 2015 04:08
-
-
Save jcromartie/5374664 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
self.currentItem.pubDate = [[[formats map:^id(id fmt) { | |
[formatter setDateFormat:fmt]; | |
return option([formatter dateFromString:text]); | |
}] find:^BOOL(id maybeDate) { | |
return ![maybeDate isEmpty]; | |
}] getOrElse:nil]; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment