summaryrefslogtreecommitdiff
path: root/app/Model/File.php
diff options
context:
space:
mode:
authorFrederic Guillot <fred@kanboard.net>2015-09-23 20:59:21 -0400
committerFrederic Guillot <fred@kanboard.net>2015-09-23 20:59:21 -0400
commit25b9e90ef3b6018f898047be025ad859fcbbd96a (patch)
treee2ad3195735200d7bf092733c8020a1249a22eac /app/Model/File.php
parent2af45250c46b431823a9bfaa28e393c70fb931d8 (diff)
Do not check anymore data folder permissions
People who are using a remote database (Mysql/Postgresql) and a remote file storage (Aws S3 or similar) don't necessary needs to have a persistent local data folder or to change the permissions.
Diffstat (limited to 'app/Model/File.php')
-rw-r--r--app/Model/File.php4
1 files changed, 4 insertions, 0 deletions
diff --git a/app/Model/File.php b/app/Model/File.php
index 7adab42b..1d44a415 100644
--- a/app/Model/File.php
+++ b/app/Model/File.php
@@ -54,6 +54,10 @@ class File extends Base
$file = $this->getbyId($file_id);
$this->objectStorage->remove($file['path']);
+ if ($file['is_image'] == 1) {
+ $this->objectStorage->remove($this->getThumbnailPath($file['path']));
+ }
+
return $this->db->table(self::TABLE)->eq('id', $file['id'])->remove();
}
catch (ObjectStorageException $e) {