diff --git a/apps/dav/lib/Avatars/AvatarNode.php b/apps/dav/lib/Avatars/AvatarNode.php index 17edf80d21..4030f48251 100644 --- a/apps/dav/lib/Avatars/AvatarNode.php +++ b/apps/dav/lib/Avatars/AvatarNode.php @@ -62,8 +62,9 @@ class AvatarNode extends File { ob_start(); if ($this->ext === 'png') { imagepng($res); + } else { + imagejpeg($res); } - imagejpeg($res); return ob_get_clean(); }