Merge branch 'master' of biodantas/gnu-social into master
This commit is contained in:
commit
723f12923c
@ -345,7 +345,13 @@ class ImageFile extends MediaFile
|
|||||||
$img = $img->orientate();
|
$img = $img->orientate();
|
||||||
}
|
}
|
||||||
|
|
||||||
$img->crop($box['width'], $box['height'], $box['x'], $box['y']);
|
$img->fit($box['width'], $box['height'],
|
||||||
|
function ($constraint) {
|
||||||
|
if (common_config('attachments', 'upscale') !== true) {
|
||||||
|
$constraint->upsize(); // Prevent upscaling
|
||||||
|
}
|
||||||
|
}
|
||||||
|
);
|
||||||
|
|
||||||
// Ensure we save in the correct format and allow customization based on type
|
// Ensure we save in the correct format and allow customization based on type
|
||||||
$type = $this->preferredType();
|
$type = $this->preferredType();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user