Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 9171d3f5 authored by Vincent Bourgmayer's avatar Vincent Bourgmayer
Browse files

Merge branch '144-o-extract-RemotefileDiff-code' into 144-o-extract-localFileDiff-code

parents f01b25e4 e15865c6
Loading
Loading
Loading
Loading
+5 −2
Original line number Diff line number Diff line
@@ -5,6 +5,7 @@
 * which accompanies this distribution, and is available at
 * http://www.gnu.org/licenses/gpl.html
 */

package foundation.e.drive.utils;

import android.util.Log;
@@ -42,12 +43,14 @@ public class FileDiffUtils {
        if (hasAlreadyBeenDownloaded(fileState) && !hasEtagChanged(remoteFile, fileState)) {
            return Action.skip;
        }

        final File localFile = new File(fileState.getLocalPath());

        if (isRemoteSizeSameAsLocalSize(remoteFile, localFile)) {
            return Action.updateDB;
        } else {
            return Action.Download;
        }

        return Action.Download;
    }


+2 −2

File changed.

Contains only whitespace changes.