From 25b9e90ef3b6018f898047be025ad859fcbbd96a Mon Sep 17 00:00:00 2001 From: Frederic Guillot Date: Wed, 23 Sep 2015 20:59:21 -0400 Subject: 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. --- app/Model/File.php | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'app/Model/File.php') 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) { -- cgit v1.2.3