Skip to content

Commit

Permalink
CC-2137: use name instead of path (#174)
Browse files Browse the repository at this point in the history
Micky Vale was still getting errors on UAT when she tried to create a
new Gloss.
This should hopefully fix this.

## JIRA Ticket
[CC-2137 NZSL: move signbank to
Poetry](https://ackama.atlassian.net/browse/CC-2137)

## Changes
- `GlossVideo` method `rename_video()` uses `name` instead of `path`
from `storage`, see Notes below

## Notes
- A Stack Overflow that describes the `path` / `name` issue:
https://stackoverflow.com/a/69135593
  • Loading branch information
jonholdsworth authored Jul 8, 2024
1 parent 1848975 commit e889a6b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion signbank/video/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ def rename_video(self):
# Set the actual file path to videofile.
self.videofile = saved_file_path

old_file.storage.delete(old_file.path)
old_file.storage.delete(old_file.name)

def create_filename(self):
"""Returns a correctly named filename"""
Expand Down

0 comments on commit e889a6b

Please sign in to comment.