Skip to content

Commit

Permalink
fix deprecated constant
Browse files Browse the repository at this point in the history
  • Loading branch information
klausi committed Jun 28, 2024
1 parent 286ee28 commit dac22bf
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
1 change: 0 additions & 1 deletion src/Config/LanguageConfigOverride.php
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,6 @@ public function getCacheSuffix() {
public function createConfigObject($name, $collection = StorageInterface::DEFAULT_COLLECTION) {
// The interface says we should return an object here, but we don't care and
// this does not seem to break anything?
// @phpstan-ignore-next-line
return NULL;
}

Expand Down
4 changes: 4 additions & 0 deletions src/GraphQL/Utility/FileUpload.php
Original file line number Diff line number Diff line change
Expand Up @@ -248,6 +248,8 @@ public function saveFileUpload(UploadedFile $uploaded_file, array $settings): Fi

$temp_file_path = $uploaded_file->getRealPath();

// Drupal 10.2 compatibility: use the deprecated constant for now.
// @phpstan-ignore-next-line
$file_uri = $this->fileSystem->getDestinationFilename($file_uri, FileSystemInterface::EXISTS_RENAME);

// Lock based on the prepared file URI.
Expand Down Expand Up @@ -291,6 +293,8 @@ public function saveFileUpload(UploadedFile $uploaded_file, array $settings): Fi
// FileSystemInterface::EXISTS_ERROR as the file location has already been
// determined above in FileSystem::getDestinationFilename().
try {
// Drupal 10.2 compatibility: use the deprecated constant for now.
// @phpstan-ignore-next-line
$this->fileSystem->move($temp_file_path, $file_uri, FileSystemInterface::EXISTS_ERROR);
}
catch (FileException $e) {
Expand Down

0 comments on commit dac22bf

Please sign in to comment.