Create ImageCompressor amd ImageCompressorImpl

* Methods from AttachmentCreationTask have been moved into them:
  * compressImage()
  * createBitmap()
* ImageCompressor is availabe via AttachmentModule
This commit is contained in:
Sebastian Kürten
2020-12-01 14:38:35 +01:00
committed by Torsten Grote
parent aa00ba7220
commit f819930570
15 changed files with 242 additions and 139 deletions

View File

@@ -302,7 +302,13 @@ public class TestDataCreatorImpl implements TestDataCreator {
AuthorId authorId = c.getAuthor().getId();
GroupId groupId = groupFactory.createGroup(AvatarManager.CLIENT_ID,
AvatarManager.MAJOR_VERSION, authorId.getBytes()).getId();
InputStream is = testAvatarCreator.getAvatarInputStream();
InputStream is;
try {
is = testAvatarCreator.getAvatarInputStream();
} catch (IOException e) {
logException(LOG, WARNING, e);
return;
}
if (is == null) return;
Message m;
try {