diff --git a/src/Container/Container.php b/src/Container/Container.php index 9ba7287..03016a3 100644 --- a/src/Container/Container.php +++ b/src/Container/Container.php @@ -18,7 +18,7 @@ public function __construct() public function addTmpFile(TmpFileInterface $tmpFile): void { if ($this->hasTmpFile($tmpFile)) { - throw new \InvalidArgumentException(sprintf('Temp file "%s" has been already added.', $tmpFile->getFilename())); + throw new \InvalidArgumentException(\sprintf('Temp file "%s" has been already added.', $tmpFile->getFilename())); } $this->tmpFiles->attach($tmpFile); @@ -32,7 +32,7 @@ public function hasTmpFile(TmpFileInterface $tmpFile): bool public function removeTmpFile(TmpFileInterface $tmpFile): void { if (!$this->hasTmpFile($tmpFile)) { - throw new \InvalidArgumentException(sprintf('Temp file "%s" hasn\'t been added yet.', $tmpFile->getFilename())); + throw new \InvalidArgumentException(\sprintf('Temp file "%s" hasn\'t been added yet.', $tmpFile->getFilename())); } $this->tmpFiles->detach($tmpFile); diff --git a/src/TmpFileManager.php b/src/TmpFileManager.php index 6ea77df..dc5a069 100644 --- a/src/TmpFileManager.php +++ b/src/TmpFileManager.php @@ -61,7 +61,7 @@ public function load(TmpFileInterface ...$tmpFiles): void foreach ($tmpFiles as $tmpFile) { if (!$this->filesystem->existsTmpFile($tmpFile)) { - throw new \InvalidArgumentException(sprintf('Temp file "%s" doesn\'t exist.', $tmpFile->getFilename())); + throw new \InvalidArgumentException(\sprintf('Temp file "%s" doesn\'t exist.', $tmpFile->getFilename())); } $this->container->addTmpFile($tmpFile); @@ -85,11 +85,11 @@ public function isolate(callable $callback): void public function remove(TmpFileInterface $tmpFile): void { if (!$this->filesystem->existsTmpFile($tmpFile)) { - throw new \InvalidArgumentException(sprintf('Temp file "%s" has been already removed.', $tmpFile->getFilename())); + throw new \InvalidArgumentException(\sprintf('Temp file "%s" has been already removed.', $tmpFile->getFilename())); } if (!$this->container->hasTmpFile($tmpFile)) { - throw new \InvalidArgumentException(sprintf('Temp file "%s" wasn\'t create through temp file manager.', $tmpFile->getFilename())); + throw new \InvalidArgumentException(\sprintf('Temp file "%s" wasn\'t create through temp file manager.', $tmpFile->getFilename())); } $this->eventDispatcher->dispatch(new TmpFilePreRemove($tmpFile));