aboutsummaryrefslogtreecommitdiffstats
path: root/Frameworks
diff options
context:
space:
mode:
Diffstat (limited to 'Frameworks')
-rw-r--r--Frameworks/QueryKit/QKQuery.m3
-rw-r--r--Frameworks/QueryKit/QKQueryParameter.m4
2 files changed, 5 insertions, 2 deletions
diff --git a/Frameworks/QueryKit/QKQuery.m b/Frameworks/QueryKit/QKQuery.m
index cda3b877..31755b6d 100644
--- a/Frameworks/QueryKit/QKQuery.m
+++ b/Frameworks/QueryKit/QKQuery.m
@@ -412,6 +412,9 @@ static NSString *QKNoQueryTableException = @"QKNoQueryTable";
#pragma mark -
+/**
+ * Same as calling -query.
+ */
- (NSString *)description
{
return [self query];
diff --git a/Frameworks/QueryKit/QKQueryParameter.m b/Frameworks/QueryKit/QKQueryParameter.m
index d131c156..bc9efa2f 100644
--- a/Frameworks/QueryKit/QKQueryParameter.m
+++ b/Frameworks/QueryKit/QKQueryParameter.m
@@ -63,12 +63,12 @@
- (NSString *)description
{
NSMutableString *string = [NSMutableString string];
-
+
NSString *field = [_field stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceAndNewlineCharacterSet]];
[string appendString:field];
[string appendFormat:@" %@ ", [QKQueryUtilities operatorRepresentationForType:_operator]];
- [string appendString:[_value description]];
+ [string appendFormat:(![_value isKindOfClass:[NSNumber class]]) ? @"'%@'" : @"%@", [_value description]];
return string;
}