mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-12-10 04:59:30 +00:00
Fixed phpstan issues
This commit is contained in:
parent
07db1554c7
commit
1bfea3c48a
6 changed files with 22 additions and 2 deletions
|
|
@ -57,6 +57,9 @@ use Symfony\Contracts\HttpClient\HttpClientInterface;
|
|||
*/
|
||||
class AttachmentSubmitHandler
|
||||
{
|
||||
/**
|
||||
* @var array<string, string> The mapping used to determine which folder will be used for an attachment type
|
||||
*/
|
||||
protected array $folder_mapping;
|
||||
|
||||
private ?int $max_upload_size_bytes = null;
|
||||
|
|
@ -160,6 +163,7 @@ class AttachmentSubmitHandler
|
|||
} else {
|
||||
//If not, check for instance of:
|
||||
foreach ($this->folder_mapping as $class => $folder) {
|
||||
/** @var string $class */
|
||||
if ($attachment instanceof $class) {
|
||||
$prefix = $folder;
|
||||
break;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue