forked from sehmaschine/django-filebrowser
-
Notifications
You must be signed in to change notification settings - Fork 95
Closed
Description
Clone of sehmaschine#358, I decided to open it here since it looks more actively maintained.
A string default for FileBrowserField does not work since it looks for .path on a string, at least on PostgreSQL:
django-filebrowser-no-grappelli/filebrowser/fields.py
Lines 113 to 116 in 62c01cb
| def get_prep_value(self, value): | |
| if not value: | |
| return value | |
| return value.path |
Of course this fails with:
AttributeError: 'str' object has no attribute 'path'
Other examples can be found in the original issue linked.
I'll submit the same PR, but maybe there is a better solution to this problem.
Metadata
Metadata
Assignees
Labels
No labels