Commit 0ff8aecc authored by vince-bourgmayer's avatar vince-bourgmayer
Browse files

change type of resultCode (string => ResultCode object)

parent e551e975
Pipeline #34175 passed with stage
in 2 minutes and 29 seconds
......@@ -241,8 +241,8 @@ public class InitializerService extends Service {
}
public void onFolderCreationResult(String resultCode, int httpResultCode){
if(resultCode.equals(RemoteOperationResult.ResultCode.OK) || resultCode.equals(RemoteOperationResult.ResultCode.FOLDER_ALREADY_EXISTS)){
public void onFolderCreationResult(RemoteOperationResult.ResultCode resultCode, int httpResultCode){
if(resultCode != null && (resultCode.equals(RemoteOperationResult.ResultCode.OK) || resultCode.equals(RemoteOperationResult.ResultCode.FOLDER_ALREADY_EXISTS))){
this.existingRemoteFolderCounter+=1;
CreateNextRemoteFolder();
}else if(httpResultCode == 423 || httpResultCode == 409){
......@@ -311,7 +311,9 @@ public class InitializerService extends Service {
if(intent == null || (extras = intent.getExtras()) == null) {
return;
}
String resultCode = extras.getString(AppConstants.resultCodeKey);
RemoteOperationResult.ResultCode resultCode = extras.getParcelable(AppConstants.resultCodeKey);
//Note: Problem with parsing parcelable to ResultCode. Probably because it's null...
int httpResultCode = extras.getInt(AppConstants.resultIntentHttpCodeKey);
onFolderCreationResult(resultCode, httpResultCode);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment