flask-admin-s3-upload
flask-admin-s3-upload copied to clipboard
remove storage_type_field and bucket_name_field
Hi,
I have removed the storage_type_field
and the bucked_name_field
and used self.storage_type
and self.bucket_name
instead.
Maybe I have misunderstood the purpose of these two field but the deletion of the files on S3 doesn't work because these lines returns an empty string:
storage_type = getattr(obj, self.storage_type_field, '')
bucket_name = getattr(obj, self.bucket_name_field, '')
Instead using self.storage_type
and self.bucket_name
returns the values we need.
Let me know if I misunderstood the behavior 😄