summaryrefslogtreecommitdiffstats
path: root/macosx
diff options
context:
space:
mode:
Diffstat (limited to 'macosx')
-rw-r--r--macosx/HBPreferencesController.m2
1 files changed, 1 insertions, 1 deletions
diff --git a/macosx/HBPreferencesController.m b/macosx/HBPreferencesController.m
index 14f988db6..d125782bd 100644
--- a/macosx/HBPreferencesController.m
+++ b/macosx/HBPreferencesController.m
@@ -219,7 +219,7 @@
- (NSString *)tokenField:(NSTokenField *)tokenField displayStringForRepresentedObject:(id)representedObject
{
- if ([representedObject rangeOfString: @"{"].location == 0)
+ if ([representedObject rangeOfString: @"{"].location == 0 && [representedObject length] > 1)
{
return [(NSString *)representedObject substringWithRange:NSMakeRange(1, [(NSString*)representedObject length]-2)];
}