Permalink
Browse files

don't let us pass nil strings into -[NSAttributedString initWithString:]

  • Loading branch information...
1 parent c85ebc5 commit 4a78970e90804db48132499bb0c0a2518a4339cf @joshaber joshaber committed Apr 16, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/UIKit/TUIAttributedString.m
@@ -26,7 +26,7 @@ @implementation TUIAttributedString
+ (TUIAttributedString *)stringWithString:(NSString *)string
{
- return (TUIAttributedString *)[[NSMutableAttributedString alloc] initWithString:string];
+ return (TUIAttributedString *)[[NSMutableAttributedString alloc] initWithString:string ? : @""];
}
@end

0 comments on commit 4a78970

Please sign in to comment.