Skip to content

Commit

Permalink
jobs can now also take string as input (useful for upload in smart al…
Browse files Browse the repository at this point in the history
…bums)
  • Loading branch information
ildyria committed Jul 4, 2023
1 parent a52fd8e commit d477538
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/Jobs/ProcessImageJob.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,12 +45,12 @@ class ProcessImageJob implements ShouldQueue
*/
public function __construct(
ProcessableJobFile $file,
?AbstractAlbum $albumId,
string|AbstractAlbum|null $albumId,
?int $fileLastModifiedTime,
) {
$this->filePath = $file->getPath();
$this->originalBaseName = $file->getOriginalBasename();
$this->albumId = $albumId?->id;
$this->albumId = is_string($albumId) ? $albumId : $albumId?->id;
$this->userId = Auth::user()->id;
$this->fileLastModifiedTime = $fileLastModifiedTime;

Expand Down

0 comments on commit d477538

Please sign in to comment.