- Introduced new components and services for OIDC app creation, enabling dynamic handling of app types, URIs, and user roles. - Added support for uploading and managing logos for connected apps. - Implemented `ClientCreationFactory` and related factories for modular OIDC client generation. - Updated UI to enhance app creation flow with post-creation credential display and improved validations. - Refactored backend with `OidcService` for streamlined OIDC app creation and management.
26 lines
494 B
PHP
26 lines
494 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace App\Services;
|
|
|
|
use Illuminate\Http\UploadedFile;
|
|
use Illuminate\Support\Facades\Storage;
|
|
|
|
final readonly class ApplicationLogoUploader
|
|
{
|
|
public function store(?UploadedFile $logo): ?string
|
|
{
|
|
return $logo?->store('application-logos', 'public');
|
|
}
|
|
|
|
public function delete(?string $path): bool
|
|
{
|
|
if (null !== $path) {
|
|
return Storage::disk('public')->delete($path);
|
|
}
|
|
|
|
return false;
|
|
}
|
|
}
|