浏览代码

Change API V2 #331

Marino Faggiana 7 年之前
父节点
当前提交
9fd9f7ce7b

+ 1 - 1
iOSClient/Library/OCCommunicationLib/OCCommunication.m

@@ -1808,7 +1808,7 @@
 - (void) getUserProfileServer:(NSString*)serverPath onCommunication:(OCCommunication *)sharedOCComunication successRequest:(void(^)(NSHTTPURLResponse *response, OCUserProfile *userProfile, NSString *redirectedServer)) successRequest failureRequest:(void(^)(NSHTTPURLResponse *response, NSError *error, NSString *redirectedServer)) failureRequest {
     
     serverPath = [serverPath stringByAppendingString:k_url_acces_remote_userprofile_api];
-    serverPath = [serverPath stringByAppendingString:self.user];
+    //serverPath = [serverPath stringByAppendingString:self.user];
     serverPath = [serverPath encodeString:NSUTF8StringEncoding];
 
     OCWebDAVClient *request = [OCWebDAVClient new];

+ 1 - 1
iOSClient/Library/OCCommunicationLib/OCErrorMsg.h

@@ -40,7 +40,7 @@
 #define kOCNotificationAPINoContent  204
 #define kOCNotificationAPISuccessful 200
 
-#define kOCUserProfileAPISuccessful 100
+#define kOCUserProfileAPISuccessful 200
 
 typedef enum {
     OCServerErrorForbiddenCharacters = 101,

+ 1 - 1
iOSClient/Library/OCCommunicationLib/OCFrameworkConstants.h

@@ -66,7 +66,7 @@
 #define k_url_acces_external_sites_api @"ocs/v2.php/apps/external/api/v1"
 
 //Url to access to User Profile API
-#define k_url_acces_remote_userprofile_api @"ocs/v1.php/cloud/users/"
+#define k_url_acces_remote_userprofile_api @"ocs/v2.php/cloud/user"
 
 //Version of the server that have share API
 #define k_version_support_shared [NSArray arrayWithObjects:  @"5", @"0", @"27", nil]