Code clean up.

This commit is contained in:
James Cole
2017-11-15 10:50:23 +01:00
parent 845d7d701f
commit aee17221eb
46 changed files with 47 additions and 93 deletions

View File

@@ -104,11 +104,9 @@ class AttachmentCollector extends BasicCollector implements CollectorInterface
$exportFile = $this->exportFileName($attachment);
$this->exportDisk->put($exportFile, $decrypted);
$this->getEntries()->push($exportFile);
} catch (DecryptException $e) {
Log::error('Catchable error: could not decrypt attachment #' . $attachment->id . ' because: ' . $e->getMessage());
}
}
return true;
@@ -123,7 +121,6 @@ class AttachmentCollector extends BasicCollector implements CollectorInterface
*/
private function exportFileName($attachment): string
{
return sprintf('%s-Attachment nr. %s - %s', $this->job->key, strval($attachment->id), $attachment->filename);
}

View File

@@ -23,7 +23,6 @@ declare(strict_types=1);
namespace FireflyIII\Export\Collector;
use FireflyIII\Models\ExportJob;
use FireflyIII\User;
use Illuminate\Support\Collection;
@@ -82,6 +81,4 @@ class BasicCollector
{
$this->user = $user;
}
}

View File

@@ -57,5 +57,4 @@ interface CollectorInterface
* @return mixed
*/
public function setJob(ExportJob $job);
}

View File

@@ -116,5 +116,4 @@ class UploadCollector extends BasicCollector implements CollectorInterface
return true;
}
}