diff options
author | Max <post@wickenrode.com> | 2015-03-09 00:00:43 +0100 |
---|---|---|
committer | Max <post@wickenrode.com> | 2015-03-09 00:00:43 +0100 |
commit | 784876380b871b6d85978a705e2477e7b7d2d984 (patch) | |
tree | 5705e92b0aab9fecdf7d37954f5a0c3e873de1ff /Source/SPTableStructure.m | |
parent | b15c7fb2d407ec8751a2579a7a68bbd8a037ccfe (diff) | |
download | sequelpro-784876380b871b6d85978a705e2477e7b7d2d984.tar.gz sequelpro-784876380b871b6d85978a705e2477e7b7d2d984.tar.bz2 sequelpro-784876380b871b6d85978a705e2477e7b7d2d984.zip |
Minimal refactoring
Replaced some (range.location + range.length) with NSMaxRange(range)
Diffstat (limited to 'Source/SPTableStructure.m')
-rw-r--r-- | Source/SPTableStructure.m | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Source/SPTableStructure.m b/Source/SPTableStructure.m index 32739eb3..992ecdcf 100644 --- a/Source/SPTableStructure.m +++ b/Source/SPTableStructure.m @@ -912,7 +912,7 @@ static NSString *SPRemoveFieldAndForeignKey = @"SPRemoveFieldAndForeignKey"; // UNSIGNED keyword. NSRange range = [queryString rangeOfString:[NSString stringWithFormat:@"%@ %@", [[theRow objectForKey:@"name"] backtickQuotedString], theRowType] options:NSLiteralSearch]; - NSInteger insertionIndex = (range.location + range.length); + NSInteger insertionIndex = NSMaxRange(range); // If the field definition's data type includes the length then we must take this into // account when inserting the UNSIGNED keyword. Add 2 to the index to accommodate the |