diff options
author | Max <post@wickenrode.com> | 2014-12-13 03:12:41 +0100 |
---|---|---|
committer | Max <post@wickenrode.com> | 2014-12-13 03:44:31 +0100 |
commit | 3cf0254e55d558565775e6cb20d36ea7e54beca1 (patch) | |
tree | 38842cf51bdfd2b28c74dba86646bc6523c767fc /Source/SPPreferencesUpgrade.m | |
parent | 4ad26db45b46d8267fcb5203571b81bc8949b853 (diff) | |
download | sequelpro-3cf0254e55d558565775e6cb20d36ea7e54beca1.tar.gz sequelpro-3cf0254e55d558565775e6cb20d36ea7e54beca1.tar.bz2 sequelpro-3cf0254e55d558565775e6cb20d36ea7e54beca1.zip |
Replace boxed integers in code with @ literals
Diffstat (limited to 'Source/SPPreferencesUpgrade.m')
-rw-r--r-- | Source/SPPreferencesUpgrade.m | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Source/SPPreferencesUpgrade.m b/Source/SPPreferencesUpgrade.m index 6151f675..a412088c 100644 --- a/Source/SPPreferencesUpgrade.m +++ b/Source/SPPreferencesUpgrade.m @@ -214,17 +214,17 @@ void SPApplyRevisionChanges(void) if ([[favorite objectForKey:@"host"] isEqualToString:@"localhost"] || ([favorite objectForKey:@"socket"] && [(NSString *)[favorite objectForKey:@"socket"] length])) { - [favorite setObject:[NSNumber numberWithInteger:1] forKey:@"type"]; + [favorite setObject:@1 forKey:@"type"]; // If SSH details are set, set to tunnel connection } else if ([favorite objectForKey:@"useSSH"] && [[favorite objectForKey:@"useSSH"] integerValue]) { - [favorite setObject:[NSNumber numberWithInteger:2] forKey:@"type"]; + [favorite setObject:@2 forKey:@"type"]; // Default to TCP/IP } else { - [favorite setObject:[NSNumber numberWithInteger:0] forKey:@"type"]; + [favorite setObject:@0 forKey:@"type"]; } // Remove SSH tunnel flag - no longer required @@ -311,7 +311,7 @@ void SPApplyRevisionChanges(void) NSNumber *newMappedValue = [encodingMap valueForKey:[prefs objectForKey:SPOldDefaultEncodingKey]]; - if (newMappedValue == nil) newMappedValue = [NSNumber numberWithInt:0]; + if (newMappedValue == nil) newMappedValue = @0; [prefs setObject:newMappedValue forKey:@"DefaultEncodingTag"]; } |