data:files Cleaned up onPostExecute() if-statements.

This commit is contained in:
ardevd 2018-05-02 12:54:43 +02:00
parent 9efa675c2a
commit 49d0ccac7d

View file

@ -126,15 +126,15 @@ public class FilesServiceApiImpl implements FilesServiceApi {
@Override
protected void onPostExecute(Boolean success) {
super.onPostExecute(success);
if (success && remoteOcFile != null) {
callback.onLoaded(remoteOcFile);
return;
} else if (success) {
errorMessage = "File not found";
}
callback.onError(errorMessage);
if (success) {
if (remoteOcFile != null) {
callback.onLoaded(remoteOcFile);
} else {
errorMessage = "File not found";
callback.onError(errorMessage);
}
}
}
}
}