diff options
Diffstat (limited to 'Source/SPStringAdditions.m')
-rw-r--r-- | Source/SPStringAdditions.m | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Source/SPStringAdditions.m b/Source/SPStringAdditions.m index 97339201..012f365c 100644 --- a/Source/SPStringAdditions.m +++ b/Source/SPStringAdditions.m @@ -537,14 +537,14 @@ if([[[NSApp mainWindow] delegate] respondsToSelector:@selector(selectedTableDocument)]) doc = [[[NSApp mainWindow] delegate] selectedTableDocument]; // Check if connected - if([[doc connectionID] isEqualToString:@"_"]) + if([doc getConnection] == nil) doc = nil; else { for (NSWindow *aWindow in [NSApp orderedWindows]) { if([[[[aWindow windowController] class] description] isEqualToString:@"SPWindowController"]) { if([[[aWindow windowController] documents] count] && [[[[[[aWindow windowController] documents] objectAtIndex:0] class] description] isEqualToString:@"SPDatabaseDocument"]) { // Check if connected - if(![[[[[aWindow windowController] documents] objectAtIndex:0] connectionID] isEqualToString:@"_"]) + if([[[[aWindow windowController] documents] objectAtIndex:0] getConnection]) doc = [[[aWindow windowController] documents] objectAtIndex:0]; else doc = nil; |