Skip to content

Fail explicitly when filesystem storage writes do not succeed #119

Description

@javihgil

Problem

FilesystemStorageDriver ignores write failures when creating directories and copying files.

Current code:

  • src/Storage/FilesystemStorageDriver.php:22 calls mkdir() without checking the result
  • src/Storage/FilesystemStorageDriver.php:26 calls copy() without checking the result

Impact

The storage driver can report a stored file path even when the file was never written successfully.

That makes failures harder to detect and can leave the database pointing to files that do not exist.

Expected behavior

  • validate directory creation and file copy operations
  • throw a storage exception when the write fails
  • keep the returned stored path only for successful writes

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions