File tree Expand file tree Collapse file tree
AppBox/Common/CLISupportHelper Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -41,12 +41,11 @@ + (BOOL)uninstall {
4141 [alert addButtonWithTitle: @" Yes" ];
4242 [alert addButtonWithTitle: @" No" ];
4343 if ([alert runModal ] == NSAlertFirstButtonReturn ){
44- NSError *error;
4544 if ([self runScript: @" uninstall.sh" ]){
4645 [Common showAlertWithTitle: @" Success" andMessage: @" AppBox CLI tool uninstalled successfully." ];
4746 return YES ;
4847 }else {
49- [Common showAlertWithTitle: @" Error" andMessage: [ NSString stringWithFormat: @" Failed to uninstall AppBox CLI tool.\n\n %@ " , error.localizedDescription] ];
48+ [Common showAlertWithTitle: @" Error" andMessage: @" Failed to uninstall AppBox CLI tool." ];
5049 return NO ;
5150 }
5251 } else {
@@ -75,12 +74,11 @@ + (BOOL)installPromptAfterLogin {
7574+ (BOOL )updatePromptAfterVersionUpdate {
7675 NSString *appVersion = [[[NSBundle mainBundle ] infoDictionary ] valueForKey: @" CFBundleShortVersionString" ];
7776 NSString *cliVersion = [UserData cliVersion ];
78- if (appVersion == cliVersion || cliVersion.isEmpty ) {
77+ if ([ appVersion isEqualToString: cliVersion] || cliVersion.isEmpty ) {
7978 return NO ;
8079 }
8180
82- BOOL hasNewCLIVersion = YES ;
83- if (![NSFileManager .defaultManager fileExistsAtPath: abCLIPath] || !hasNewCLIVersion) {
81+ if (![NSFileManager .defaultManager fileExistsAtPath: abCLIPath]) {
8482 return NO ;
8583 }
8684
You can’t perform that action at this time.
0 commit comments