Revision: 29371
          http://sourceforge.net/p/bibdesk/svn/29371
Author:   hofman
Date:     2025-07-26 16:04:41 +0000 (Sat, 26 Jul 2025)
Log Message:
-----------
return early for success

Modified Paths:
--------------
    trunk/bibdesk/BDSKEditor.m

Modified: trunk/bibdesk/BDSKEditor.m
===================================================================
--- trunk/bibdesk/BDSKEditor.m  2025-07-26 16:03:04 UTC (rev 29370)
+++ trunk/bibdesk/BDSKEditor.m  2025-07-26 16:04:41 UTC (rev 29371)
@@ -2253,12 +2253,12 @@
 
 - (NSError *)errorForTextShouldEndEditing:(NSText *)aTextObject{
     BDSKASSERT(aTextObject == currentEditedView);
-    if (NO == [[currentEditedView string] 
isStringTeXQuotingBalancedWithBraces:YES connected:NO]) {
-        NSError *err = [NSError mutableLocalErrorWithCode:kBDSKFailedToCommit 
localizedDescription:NSLocalizedString(@"Invalid Value", @"Message in alert 
dialog when entering an invalid value")];
-        [err setValue:NSLocalizedString(@"The value you entered contains 
unbalanced braces and cannot be saved.", @"Informative text in alert dialog") 
forKey:NSLocalizedRecoverySuggestionErrorKey];
-        return err;
-    }
-    return nil;
+    if ([[currentEditedView string] isStringTeXQuotingBalancedWithBraces:YES 
connected:NO])
+        return nil;
+
+    NSError *err = [NSError mutableLocalErrorWithCode:kBDSKFailedToCommit 
localizedDescription:NSLocalizedString(@"Invalid Value", @"Message in alert 
dialog when entering an invalid value")];
+    [err setValue:NSLocalizedString(@"The value you entered contains 
unbalanced braces and cannot be saved.", @"Informative text in alert dialog") 
forKey:NSLocalizedRecoverySuggestionErrorKey];
+    return err;
 }
 
 - (BOOL)textShouldEndEditing:(NSText *)aTextObject {

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.



_______________________________________________
Bibdesk-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bibdesk-commit

Reply via email to