Skip to content

Commit

Permalink
Replaced naming filename for FileSystemStorage
Browse files Browse the repository at this point in the history
  • Loading branch information
hannal committed Apr 26, 2024
1 parent 0ce6ffa commit 2f8de73
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions fastapi_storages/filesystem.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,8 @@ def write(self, file: BinaryIO, name: str) -> str:
Write input file which is opened in binary mode to destination.
"""

filename = secure_filename(name)
path = self._path / Path(filename)
filename = self.get_name(name)
path = self.get_path(filename)

file.seek(0, 0)
with open(path, "wb") as output:
Expand Down

0 comments on commit 2f8de73

Please sign in to comment.