@@ -33,6 +33,6 @@ |
||
| 33 | 33 | */ |
| 34 | 34 | public function getHeader() |
| 35 | 35 | { |
| 36 | - return []; |
|
| 36 | + return [ ]; |
|
| 37 | 37 | } |
| 38 | 38 | } |
@@ -164,8 +164,9 @@ |
||
| 164 | 164 | */ |
| 165 | 165 | protected function makeRows() |
| 166 | 166 | { |
| 167 | - if ( ! empty($headerRow = $this->serializer->getHeader())) |
|
| 168 | - $this->writer->addRow($headerRow); |
|
| 167 | + if ( ! empty($headerRow = $this->serializer->getHeader())) { |
|
| 168 | + $this->writer->addRow($headerRow); |
|
| 169 | + } |
|
| 169 | 170 | |
| 170 | 171 | foreach ($this->data as $record) { |
| 171 | 172 | $this->writer->addRow( |
@@ -19,7 +19,7 @@ discard block |
||
| 19 | 19 | */ |
| 20 | 20 | |
| 21 | 21 | /** @var array */ |
| 22 | - protected $data = []; |
|
| 22 | + protected $data = [ ]; |
|
| 23 | 23 | |
| 24 | 24 | /** @var string */ |
| 25 | 25 | protected $type; |
@@ -31,7 +31,7 @@ discard block |
||
| 31 | 31 | protected $writer; |
| 32 | 32 | |
| 33 | 33 | /** @var array */ |
| 34 | - protected $options = []; |
|
| 34 | + protected $options = [ ]; |
|
| 35 | 35 | |
| 36 | 36 | /* ----------------------------------------------------------------- |
| 37 | 37 | | Constructor |
@@ -43,7 +43,7 @@ discard block |
||
| 43 | 43 | * |
| 44 | 44 | * @param array $options |
| 45 | 45 | */ |
| 46 | - public function __construct(array $options = []) |
|
| 46 | + public function __construct(array $options = [ ]) |
|
| 47 | 47 | { |
| 48 | 48 | $this->setSerializer(new DefaultSerializer); |
| 49 | 49 | $this->setOptions($options); |
@@ -197,7 +197,9 @@ |
||
| 197 | 197 | $rows = Collection::make(); |
| 198 | 198 | |
| 199 | 199 | foreach ($this->reader->getSheetIterator() as $index => $sheet) { |
| 200 | - if ($index !== $this->sheet) continue; |
|
| 200 | + if ($index !== $this->sheet) { |
|
| 201 | + continue; |
|
| 202 | + } |
|
| 201 | 203 | |
| 202 | 204 | foreach ($sheet->getRowIterator() as $row) { |
| 203 | 205 | $rows->push($this->parser->transform($row)); |
@@ -34,7 +34,7 @@ discard block |
||
| 34 | 34 | protected $reader; |
| 35 | 35 | |
| 36 | 36 | /** @var array */ |
| 37 | - protected $options = []; |
|
| 37 | + protected $options = [ ]; |
|
| 38 | 38 | |
| 39 | 39 | /* ----------------------------------------------------------------- |
| 40 | 40 | | Constructor |
@@ -46,7 +46,7 @@ discard block |
||
| 46 | 46 | * |
| 47 | 47 | * @param array $options |
| 48 | 48 | */ |
| 49 | - public function __construct(array $options = []) |
|
| 49 | + public function __construct(array $options = [ ]) |
|
| 50 | 50 | { |
| 51 | 51 | $this->setParser(new DefaultParser); |
| 52 | 52 | $this->setOptions($options); |
@@ -27,7 +27,7 @@ discard block |
||
| 27 | 27 | * |
| 28 | 28 | * @var bool |
| 29 | 29 | */ |
| 30 | - protected $defer = true; |
|
| 30 | + protected $defer = true; |
|
| 31 | 31 | |
| 32 | 32 | /* ----------------------------------------------------------------- |
| 33 | 33 | | Main Methods |
@@ -76,7 +76,7 @@ discard block |
||
| 76 | 76 | */ |
| 77 | 77 | private function registerExporterManager() |
| 78 | 78 | { |
| 79 | - $this->singleton(Contracts\ExporterManager::class, function ($app) { |
|
| 79 | + $this->singleton(Contracts\ExporterManager::class, function($app) { |
|
| 80 | 80 | return new ExporterManager($app); |
| 81 | 81 | }); |
| 82 | 82 | } |
@@ -86,7 +86,7 @@ discard block |
||
| 86 | 86 | */ |
| 87 | 87 | private function registerImporterManager() |
| 88 | 88 | { |
| 89 | - $this->singleton(Contracts\ImporterManager::class, function ($app) { |
|
| 89 | + $this->singleton(Contracts\ImporterManager::class, function($app) { |
|
| 90 | 90 | return new ImporterManager($app); |
| 91 | 91 | }); |
| 92 | 92 | } |
@@ -22,7 +22,7 @@ discard block |
||
| 22 | 22 | */ |
| 23 | 23 | public function getDefaultDriver() |
| 24 | 24 | { |
| 25 | - return $this->app['config']->get('excel.default'); |
|
| 25 | + return $this->app[ 'config' ]->get('excel.default'); |
|
| 26 | 26 | } |
| 27 | 27 | |
| 28 | 28 | /* ----------------------------------------------------------------- |
@@ -39,6 +39,6 @@ discard block |
||
| 39 | 39 | */ |
| 40 | 40 | protected function getDriverOptions($driver) |
| 41 | 41 | { |
| 42 | - return $this->app['config']->get("excel.drivers.$driver.options", []); |
|
| 42 | + return $this->app[ 'config' ]->get("excel.drivers.$driver.options", [ ]); |
|
| 43 | 43 | } |
| 44 | 44 | } |