diff options
author | Christian Schneppe <christian@pix-art.de> | 2016-08-30 22:35:57 +0200 |
---|---|---|
committer | Christian Schneppe <christian@pix-art.de> | 2016-08-30 22:35:57 +0200 |
commit | 0b4f6dff57409c121d2db105902b42e830c56b56 (patch) | |
tree | e175153c11f8f6631566ec0f7aaa7ced4c1fd9f3 /src/main/java | |
parent | e38ef5e22dd2429e919c20cca413db711cb7b740 (diff) |
change filename pattern
Diffstat (limited to 'src/main/java')
-rw-r--r-- | src/main/java/de/pixart/messenger/persistance/FileBackend.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/main/java/de/pixart/messenger/persistance/FileBackend.java b/src/main/java/de/pixart/messenger/persistance/FileBackend.java index 2972c71de..2ffcbb7ec 100644 --- a/src/main/java/de/pixart/messenger/persistance/FileBackend.java +++ b/src/main/java/de/pixart/messenger/persistance/FileBackend.java @@ -281,7 +281,8 @@ public class FileBackend { if (extension == null) { extension = getExtensionFromUri(uri); } - message.setRelativeFilePath(message.getUuid() + "." + extension); + String filename = fileDateFormat.format(new Date(message.getTimeSent()))+"_"+message.getUuid().substring(0,4); + message.setRelativeFilePath(filename + "." + extension); copyFileToPrivateStorage(mXmppConnectionService.getFileBackend().getFile(message), uri); } |