mirror of
https://github.com/samsonjs/Marshmallows.git
synced 2026-04-27 15:07:42 +00:00
fix some warnings and notes
This commit is contained in:
parent
d3436be10a
commit
f28626d097
3 changed files with 6 additions and 6 deletions
|
|
@ -278,7 +278,7 @@ NSString *JoinURLComponents(NSString *first, va_list args)
|
||||||
if (_baseURL && !([url hasPrefix: @"http:"] || [url hasPrefix: @"https:"])) {
|
if (_baseURL && !([url hasPrefix: @"http:"] || [url hasPrefix: @"https:"])) {
|
||||||
[mutableOptions setObject: [self urlWithPath: url] forKey: @"url"];
|
[mutableOptions setObject: [self urlWithPath: url] forKey: @"url"];
|
||||||
}
|
}
|
||||||
NSUInteger timeout = [[options objectForKey: @"timeout"] unsignedIntValue];
|
NSUInteger timeout = [[options objectForKey: @"timeout"] unsignedLongValue];
|
||||||
if (timeout == 0) {
|
if (timeout == 0) {
|
||||||
[mutableOptions setValue: [NSNumber numberWithUnsignedLong: self.timeout] forKey: @"timeout"];
|
[mutableOptions setValue: [NSNumber numberWithUnsignedLong: self.timeout] forKey: @"timeout"];
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -30,10 +30,10 @@ NSString* URLEncode(NSString *string) {
|
||||||
{
|
{
|
||||||
NSRegularExpression *regex = [NSRegularExpression
|
NSRegularExpression *regex = [NSRegularExpression
|
||||||
regularExpressionWithPattern: pattern
|
regularExpressionWithPattern: pattern
|
||||||
options: 0
|
options: NSMatchingReportCompletion
|
||||||
error: NULL];
|
error: NULL];
|
||||||
NSRange match = [regex rangeOfFirstMatchInString: self
|
NSRange match = [regex rangeOfFirstMatchInString: self
|
||||||
options: NSMatchingCompleted
|
options: NSMatchingReportCompletion
|
||||||
range: NSMakeRange(0, self.length)];
|
range: NSMakeRange(0, self.length)];
|
||||||
return match.location == NSNotFound ? nil : [self substringWithRange: match];
|
return match.location == NSNotFound ? nil : [self substringWithRange: match];
|
||||||
}
|
}
|
||||||
|
|
@ -45,7 +45,7 @@ NSString* URLEncode(NSString *string) {
|
||||||
options: NSRegularExpressionCaseInsensitive
|
options: NSRegularExpressionCaseInsensitive
|
||||||
error: NULL];
|
error: NULL];
|
||||||
return [regex stringByReplacingMatchesInString: self
|
return [regex stringByReplacingMatchesInString: self
|
||||||
options: NSMatchingCompleted
|
options: NSMatchingReportCompletion
|
||||||
range: NSMakeRange(0, [self length])
|
range: NSMakeRange(0, [self length])
|
||||||
withTemplate: @""];
|
withTemplate: @""];
|
||||||
}
|
}
|
||||||
|
|
@ -54,7 +54,7 @@ NSString* URLEncode(NSString *string) {
|
||||||
{
|
{
|
||||||
NSRegularExpression *regex = [NSRegularExpression
|
NSRegularExpression *regex = [NSRegularExpression
|
||||||
regularExpressionWithPattern: pattern
|
regularExpressionWithPattern: pattern
|
||||||
options: 0
|
options: NSMatchingReportCompletion
|
||||||
error: NULL];
|
error: NULL];
|
||||||
NSRange match = [regex rangeOfFirstMatchInString: self
|
NSRange match = [regex rangeOfFirstMatchInString: self
|
||||||
options: NSMatchingCompleted
|
options: NSMatchingCompleted
|
||||||
|
|
|
||||||
|
|
@ -9,7 +9,7 @@
|
||||||
#import <Foundation/Foundation.h>
|
#import <Foundation/Foundation.h>
|
||||||
#import <UIKit/UIKit.h>
|
#import <UIKit/UIKit.h>
|
||||||
|
|
||||||
typedef void (^UIAlertViewCallback)(long buttonClicked, BOOL canceled);
|
typedef void (^UIAlertViewCallback)(NSInteger buttonClicked, BOOL canceled);
|
||||||
|
|
||||||
@interface UIAlertViewDelegate : NSObject <UIAlertViewDelegate>
|
@interface UIAlertViewDelegate : NSObject <UIAlertViewDelegate>
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue