project_files/HedgewarsMobile/Classes/SchemeWeaponConfigViewController.m
branchios-revival
changeset 11242 e529b597f9d1
parent 11193 0fdef687de65
child 11277 bb6c553162c5
--- a/project_files/HedgewarsMobile/Classes/SchemeWeaponConfigViewController.m	Sat Oct 24 01:42:31 2015 +0200
+++ b/project_files/HedgewarsMobile/Classes/SchemeWeaponConfigViewController.m	Sat Oct 24 02:26:54 2015 +0200
@@ -329,7 +329,7 @@
             }
             else
             {
-                if (![scheme isEqualToString:@"*"])
+                if (scheme && ![scheme isEqualToString:@"*"])
                 {
                     NSString *correctScheme = [scheme stringByReplacingOccurrencesOfString:@"_" withString:@" "];
                     self.selectedScheme = [NSString stringWithFormat:@"%@.plist", correctScheme];
@@ -345,7 +345,7 @@
             }
             else
             {
-                if (![weapon isEqualToString:@"*"])
+                if (weapon && ![weapon isEqualToString:@"*"])
                 {
                     NSString *correctWeapon = [weapon stringByReplacingOccurrencesOfString:@"_" withString:@" "];
                     self.selectedWeapon = [NSString stringWithFormat:@"%@.plist", correctWeapon];