@@ -157,17 +157,17 @@ |
||
| 157 | 157 | DIRECTORY_SEPARATOR.$folder.DIRECTORY_SEPARATOR; |
| 158 | 158 | |
| 159 | 159 | // Copy files |
| 160 | - File::copyDirectory($updateFile.'app', base_path().DIRECTORY_SEPARATOR.'app'); |
|
| 160 | + File::copyDirectory($updateFile.'app', base_path().DIRECTORY_SEPARATOR.'app'); |
|
| 161 | 161 | File::copyDirectory($updateFile.'bootstrap', base_path().DIRECTORY_SEPARATOR.'bootstrap'); |
| 162 | - File::copyDirectory($updateFile.'config', base_path().DIRECTORY_SEPARATOR.'config'); |
|
| 163 | - File::copyDirectory($updateFile.'database', base_path().DIRECTORY_SEPARATOR.'database'); |
|
| 164 | - File::copyDirectory($updateFile.'public', base_path().DIRECTORY_SEPARATOR.'public'); |
|
| 162 | + File::copyDirectory($updateFile.'config', base_path().DIRECTORY_SEPARATOR.'config'); |
|
| 163 | + File::copyDirectory($updateFile.'database', base_path().DIRECTORY_SEPARATOR.'database'); |
|
| 164 | + File::copyDirectory($updateFile.'public', base_path().DIRECTORY_SEPARATOR.'public'); |
|
| 165 | 165 | File::copyDirectory($updateFile.'resources', base_path().DIRECTORY_SEPARATOR.'resources'); |
| 166 | - File::copyDirectory($updateFile.'routes', base_path().DIRECTORY_SEPARATOR.'routes'); |
|
| 167 | - File::copy($updateFile.'composer.json', base_path().DIRECTORY_SEPARATOR.'composer.json'); |
|
| 168 | - File::copy($updateFile.'composer.lock', base_path().DIRECTORY_SEPARATOR.'composer.lock'); |
|
| 169 | - File::copy($updateFile.'package.json', base_path().DIRECTORY_SEPARATOR.'package.json'); |
|
| 170 | - File::copy($updateFile.'package-lock.json', base_path().DIRECTORY_SEPARATOR.'package-lock.json'); |
|
| 166 | + File::copyDirectory($updateFile.'routes', base_path().DIRECTORY_SEPARATOR.'routes'); |
|
| 167 | + File::copy($updateFile.'composer.json', base_path().DIRECTORY_SEPARATOR.'composer.json'); |
|
| 168 | + File::copy($updateFile.'composer.lock', base_path().DIRECTORY_SEPARATOR.'composer.lock'); |
|
| 169 | + File::copy($updateFile.'package.json', base_path().DIRECTORY_SEPARATOR.'package.json'); |
|
| 170 | + File::copy($updateFile.'package-lock.json', base_path().DIRECTORY_SEPARATOR.'package-lock.json'); |
|
| 171 | 171 | |
| 172 | 172 | // Run Composer Updates |
| 173 | 173 | exec('cd '.base_path().' && composer install --no-dev --no-interaction --optimize-autoloader --no-ansi > /dev/null 2>&1'); |
@@ -76,7 +76,8 @@ |
||
| 76 | 76 | $this->line(''); |
| 77 | 77 | |
| 78 | 78 | $anticipate = []; |
| 79 | - foreach($updateList as $key => $up) { |
|
| 79 | + foreach($updateList as $key => $up) |
|
| 80 | + { |
|
| 80 | 81 | $opt = $key + 1; |
| 81 | 82 | $anticipate[$opt] = $up; |
| 82 | 83 | $this->line('['.$opt.'] '.$up); |
@@ -103,10 +103,13 @@ |
||
| 103 | 103 | { |
| 104 | 104 | Log::debug('Route '.Route::currentRouteName().' visited by '.Auth::user()->full_name); |
| 105 | 105 | |
| 106 | - try { |
|
| 106 | + try |
|
| 107 | + { |
|
| 107 | 108 | // Try to delete file type from database - will throw error if foreign key is in use |
| 108 | 109 | CustomerFileTypes::find($id)->delete(); |
| 109 | - } catch(\Illuminate\Database\QueryException $e) { |
|
| 110 | + } |
|
| 111 | + catch(\Illuminate\Database\QueryException $e) |
|
| 112 | + { |
|
| 110 | 113 | // Unable to remove file type from the database |
| 111 | 114 | Log::warning('Attempt to delete file type ID '.$id.' by User '.Auth::user()->full_name.' failed. Reason - '.$e); |
| 112 | 115 | return response()->json(['success' => false, 'reason' => 'In Use']); |
@@ -26,7 +26,8 @@ |
||
| 26 | 26 | ->orderBy('expire', 'desc')->get(); |
| 27 | 27 | |
| 28 | 28 | Log::debug('Retrieved all File Links for User ID '.$this->id.'. Data Gathered - ', array($links)); |
| 29 | - if($this->collection) { |
|
| 29 | + if($this->collection) |
|
| 30 | + { |
|
| 30 | 31 | return new FileLinksCollection($links); |
| 31 | 32 | } |
| 32 | 33 | |
@@ -128,7 +128,8 @@ |
||
| 128 | 128 | { |
| 129 | 129 | $data = Files::find($fileID); |
| 130 | 130 | // Move the file to the proper folder |
| 131 | - try { |
|
| 131 | + try |
|
| 132 | + { |
|
| 132 | 133 | Log::debug('Attempting to moving file '.$fileID.' to '.$newPath); |
| 133 | 134 | Storage::move($data->file_link.$data->file_name, $newPath.DIRECTORY_SEPARATOR.$data->file_name); |
| 134 | 135 | } |