File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -18,15 +18,15 @@ - (id)initWithString:(NSString *)string {
1818 _address = [query substringToIndex: queryStart.location];
1919
2020 NSRange amountStart = [query rangeOfString: @" amount=" ];
21- NSString * amountAndMore = [query substringFromIndex: amountStart.location + 7 ];
22-
23- NSRange additionalQueryStart = [amountAndMore rangeOfString: @" &" ];
24- if (additionalQueryStart.length > 0 ) {
25- // more parms in query, cut of
26- amountAndMore = [amountAndMore substringToIndex: additionalQueryStart.location];
21+ if (amountStart.length > 0 ) {
22+ NSString * amountAndMore = [query substringFromIndex: amountStart.location + 7 ];
23+ NSRange additionalQueryStart = [amountAndMore rangeOfString: @" &" ];
24+ if (additionalQueryStart.length > 0 ) {
25+ // more parms in query, cut of
26+ amountAndMore = [amountAndMore substringToIndex: additionalQueryStart.location];
27+ }
28+ _amount = amountAndMore;
2729 }
28-
29- _amount = amountAndMore;
3030 }
3131 }
3232 return self;
You can’t perform that action at this time.
0 commit comments