Skip to content

Commit 3ca27bf

Browse files
committed
Merge branch 'staging' into deployment
2 parents 5080934 + 1fea268 commit 3ca27bf

File tree

6 files changed

+254
-194
lines changed

6 files changed

+254
-194
lines changed

.env.example

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ APP_NAME=Mars
22
APP_ENV=local
33
APP_KEY=
44
APP_DEBUG=true
5-
APP_URL=http://localhost
5+
APP_URL=http://localhost:8000
66

77
WIFI_DOMAIN=wifi.example.net
88
WIFI_SSID=EXAMPLE_SSID

app/Http/Controllers/StudentsCouncil/EpistolaController.php

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
use Illuminate\Http\Request;
88
use Illuminate\Support\Facades\Mail;
99
use App\Mail\EpistolaCollegii;
10-
use Image;
10+
use Intervention\Image\ImageManager;
1111

1212
use App\Models\EpistolaNews;
1313

@@ -95,9 +95,8 @@ public function updateOrCreate(Request $request)
9595
//store and resize uploaded picture
9696
if ($request->picture_upload != null) {
9797
$path = $request->file('picture_upload')->store('', 'epistola');
98-
Image::make(public_path('/img/epistola/' . $path))->resize(self::IMAGE_TARGET_SIZE, null, function ($constraint) {
99-
$constraint->aspectRatio();
100-
})->save();
98+
$image = ImageManager::imagick()->read(public_path('/img/epistola/' . $path));
99+
$image->scale(self::IMAGE_TARGET_SIZE)->save();
101100
$picture_path = config('app.url') . '/img/epistola/' . $path;
102101
}
103102
$values = $request->except(['picture_path', 'id']);

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
"require": {
1111
"php": "^8.2",
1212
"graham-campbell/markdown": "^15.0",
13-
"intervention/image": "^2.5",
13+
"intervention/image": "^3.10",
1414
"laravel/framework": "^11.0",
1515
"laravel/tinker": "^2.0",
1616
"laravel/ui": "^4.0",

0 commit comments

Comments
 (0)