X-Git-Url: http://git.linex4red.de/pub/Android/ownCloud.git/blobdiff_plain/b83064eb8326c38d7c7e4a154abb1becbda72d48..ccfd7772dfd9bb5ab6bb340ffca0ed090cae1231:/src/com/owncloud/android/files/services/FileDownloader.java diff --git a/src/com/owncloud/android/files/services/FileDownloader.java b/src/com/owncloud/android/files/services/FileDownloader.java index 5e80f5d3..14a31fe9 100644 --- a/src/com/owncloud/android/files/services/FileDownloader.java +++ b/src/com/owncloud/android/files/services/FileDownloader.java @@ -1,5 +1,6 @@ /* ownCloud Android client application * Copyright (C) 2012 Bartek Przybylski + * Copyright (C) 2012-2013 ownCloud Inc. * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -198,6 +199,7 @@ public class FileDownloader extends Service implements OnDatatransferProgressLis * @param file A file that could be in the queue of downloads. */ public boolean isDownloading(Account account, OCFile file) { + if (account == null || file == null) return false; String targetKey = buildRemoteName(account, file); synchronized (mPendingDownloads) { if (file.isDirectory()) { @@ -301,6 +303,7 @@ public class FileDownloader extends Service implements OnDatatransferProgressLis file.setLastSyncDateForProperties(syncDate); file.setLastSyncDateForData(syncDate); file.setModificationTimestamp(mCurrentDownload.getModificationTimestamp()); + file.setModificationTimestampAtLastSyncForData(mCurrentDownload.getModificationTimestamp()); // file.setEtag(mCurrentDownload.getEtag()); // TODO Etag, where available file.setMimetype(mCurrentDownload.getMimeType()); file.setStoragePath(mCurrentDownload.getSavePath());