Update the mutable URL request when switching out the URL or resourcePath

This commit is contained in:
Blake Watters
2011-07-24 19:15:45 -04:00
parent 406c5a1f7c
commit 7c6507cacf

View File

@@ -521,6 +521,13 @@
return resourcePath;
}
- (void)setURL:(NSURL *)URL {
[URL retain];
[_URL release];
_URL = URL;
_URLRequest.URL = URL;
}
- (void)setResourcePath:(NSString *)resourcePath {
if ([self.URL isKindOfClass:[RKURL class]]) {
self.URL = [RKURL URLWithBaseURLString:[(RKURL*)self.URL baseURLString] resourcePath:resourcePath];