mirror of
https://github.com/camptocamp/odoo-cloud-platform.git
synced 2026-06-24 02:08:36 +00:00
fix: check if container is available to check delete
This commit is contained in:
@@ -206,6 +206,8 @@ class IrAttachment(models.Model):
|
|||||||
else:
|
else:
|
||||||
container_name = None
|
container_name = None
|
||||||
container_client = self._get_azure_container(container_name)
|
container_client = self._get_azure_container(container_name)
|
||||||
|
if not container_client:
|
||||||
|
return ''
|
||||||
# delete the file only if it is on the current configured container
|
# delete the file only if it is on the current configured container
|
||||||
# otherwise, we might delete files used on a different environment
|
# otherwise, we might delete files used on a different environment
|
||||||
try:
|
try:
|
||||||
|
|||||||
Reference in New Issue
Block a user