From c8be0f09cf84fbecd40fa93f43f1023b884c218d Mon Sep 17 00:00:00 2001 From: Alex Slubsky Date: Thu, 12 Nov 2015 09:53:51 +0200 Subject: [PATCH] Update Upload.php --- src/Bazalt/Rest/Exception/Upload.php | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/Bazalt/Rest/Exception/Upload.php b/src/Bazalt/Rest/Exception/Upload.php index 73b1ee0..0ad0ffe 100644 --- a/src/Bazalt/Rest/Exception/Upload.php +++ b/src/Bazalt/Rest/Exception/Upload.php @@ -26,6 +26,15 @@ public function getAllowedExtensions() return $this->_allowedExtensions; } + public function toArray() + { + $arr = array(); + $arr['error'] = $this->getMessage(); + $arr['code'] = $this->getCode(); + $arr['allowed_extensions'] = $this->_allowedExtensions; + return $arr; + } + /** * *