diff --git a/templates/machine.m.motemplate b/templates/machine.m.motemplate index 5995466e..a4ddc399 100644 --- a/templates/machine.m.motemplate +++ b/templates/machine.m.motemplate @@ -105,10 +105,10 @@ const struct <$managedObjectClassName$>FetchedProperties <$managedObjectClassNam NSError *error = nil; id result = [self fetch<$FetchRequest.name.initialCapitalString$>:moc_ <$foreach Binding FetchRequest.bindings do2$><$Binding.name$>:<$Binding.name$>_ <$endforeach do2$>error:&error]; if (error) { -#if TARGET_OS_IPHONE - NSLog(@"error: %@", error); -#else +#ifdef NSAppKitVersionNumber10_0 [NSApp presentError:error]; +#else + NSLog(@"error: %@", error); #endif } return result; @@ -158,10 +158,10 @@ const struct <$managedObjectClassName$>FetchedProperties <$managedObjectClassNam NSError *error = nil; NSArray *result = [self fetch<$FetchRequest.name.initialCapitalString$>:moc_ <$foreach Binding FetchRequest.bindings do2$><$Binding.name$>:<$Binding.name$>_ <$endforeach do2$>error:&error]; if (error) { -#if TARGET_OS_IPHONE - NSLog(@"error: %@", error); -#else +#ifdef NSAppKitVersionNumber10_0 [NSApp presentError:error]; +#else + NSLog(@"error: %@", error); #endif } return result;