浏览代码

Add error logging for migrating to cloud storage failures

Andy Blyler 2 年之前
父节点
当前提交
82bd1512fe
共有 1 个文件被更改,包括 3 次插入0 次删除
  1. 3 0
      app/Console/Commands/CloudMediaMigrate.php

+ 3 - 0
app/Console/Commands/CloudMediaMigrate.php

@@ -66,10 +66,13 @@ class CloudMediaMigrate extends Command
                     try {
                         MediaStorageService::store($media);
                     } catch (FileNotFoundException $e) {
+                        $this->error('Error migrating media ' . $media->id . ' to cloud storage: ' . $e->getMessage());
                         return;
                     } catch (NotFoundHttpException $e) {
+                        $this->error('Error migrating media ' . $media->id . ' to cloud storage: ' . $e->getMessage());
                         return;
                     } catch (\Exception $e) {
+                        $this->error('Error migrating media ' . $media->id . ' to cloud storage: ' . $e->getMessage());
                         return;
                     }
                 }