Larastan Level 1

pull/7362/head
Your Name 5 days ago
parent 53b698ec48
commit 2be73c4879

@ -84,6 +84,7 @@ class AvatarController extends Controller
{
$padded = str_pad($id, 19, 0, STR_PAD_LEFT);
$parts = str_split($padded, 3);
$avatarpath = '';
foreach ($parts as $k => $part) {
if ($k === 0) {
$prefix = storage_path('app/public/avatars/'.$parts[0]);

@ -216,6 +216,7 @@ class DiscoverController extends Controller
$pid = $request->user()->profile_id;
abort_if(! $this->config()['memories']['enabled'], 404);
$type = $request->input('type') ?? 'posts';
$res = collect();
switch ($type) {
case 'posts':

@ -325,6 +325,7 @@ class GroupController extends GroupFederationController
$type = $request->input('type');
$item = $request->input('item');
$res = null;
switch ($type) {
case 'instance':

@ -173,6 +173,7 @@ class PublicApiController extends Controller
$scope = ['public', 'unlisted'];
}
$replies = collect();
if ($request->filled('min_id') || $request->filled('max_id')) {
if ($request->filled('min_id')) {
$replies = $status->comments()

@ -14,6 +14,7 @@ trait RelationshipSettings
$mode = $request->input('mode') ?? 'followers';
$profile = $request->user()->profile;
$data = null;
switch ($mode) {
case 'following':

@ -99,7 +99,7 @@ class ImageS3UploadPipeline implements ShouldQueue
return $disk->url($file);
} catch (S3Exception|ClientException|ConnectException|UnableToWriteFile|Exception $e) {
Log::warning("Groups ImageS3UploadPipeline: Failed to handle Resilient Store {$file} : ".$e->getMessage());
Log::warning('Groups ImageS3UploadPipeline: Failed to handle Resilient Store : '.$e->getMessage());
throw $e;
}
}, function (int $attempt, Exception $exception) {

@ -81,6 +81,7 @@ class ImportInstagram implements ShouldQueue
foreach ($collection as $import) {
$caption = $import['caption'];
$taken_at = now();
try {
$min = Carbon::create(2010, 10, 6, 0, 0, 0);
$taken_at = Carbon::parse($import['taken_at']);

@ -178,6 +178,8 @@ class MediaStorageService
return;
}
$ext = '';
switch ($mime) {
case 'image/png':
$ext = '.png';

@ -47,7 +47,7 @@ class ResilientMediaStorageService
return $disk->url($file);
} catch (S3Exception|ClientException|ConnectException|UnableToWriteFile|Exception $e) {
Log::warning("ResilientMediaStorageService: Failed to handle Resilient Store {$file} : ".$e->getMessage());
Log::warning('ResilientMediaStorageService: Failed to handle Resilient Store : '.$e->getMessage());
throw $e;
}
}, function (int $attempt, Exception $exception) {

Loading…
Cancel
Save