aboutsummaryrefslogtreecommitdiffstats
path: root/Source/CustomQuery.m
diff options
context:
space:
mode:
Diffstat (limited to 'Source/CustomQuery.m')
-rw-r--r--Source/CustomQuery.m4
1 files changed, 2 insertions, 2 deletions
diff --git a/Source/CustomQuery.m b/Source/CustomQuery.m
index 358361b6..48de864f 100644
--- a/Source/CustomQuery.m
+++ b/Source/CustomQuery.m
@@ -669,14 +669,14 @@
[[SPQueryController sharedQueryController] addHistory:usedQuery forFileURL:[tableDocumentInstance fileURL]];
// Add it to the document's current popup list
- if([queryHistoryButton numberOfItems] > 8)
+ if([queryHistoryButton numberOfItems] > 7)
[queryHistoryButton insertItemWithTitle:usedQuery atIndex:7];
else
[queryHistoryButton addItemWithTitle:usedQuery];
// Check for max history
NSUInteger maxHistoryItems = [[prefs objectForKey:SPCustomQueryMaxHistoryItems] intValue];
- while ( [queryHistoryButton numberOfItems] > maxHistoryItems + 6 )
+ while ( [queryHistoryButton numberOfItems] > maxHistoryItems + 7 )
[queryHistoryButton removeItemAtIndex:[queryHistoryButton numberOfItems]-1];
}