@@ -112,8 +112,9 @@ discard block |
||
| 112 | 112 | */ |
| 113 | 113 | private function isParentFolderAllowed($parent_id, $user_accessible_folders, $user_is_admin, $user_can_create_root_folder) |
| 114 | 114 | { |
| 115 | - if ($parent_id == 0 && $user_can_create_root_folder == true) |
|
| 116 | - return true; |
|
| 115 | + if ($parent_id == 0 && $user_can_create_root_folder == true) { |
|
| 116 | + return true; |
|
| 117 | + } |
|
| 117 | 118 | |
| 118 | 119 | if (in_array($parent_id, $user_accessible_folders) === false |
| 119 | 120 | && (int) $user_is_admin !== 1 |
@@ -438,8 +439,9 @@ discard block |
||
| 438 | 439 | )['count']; |
| 439 | 440 | |
| 440 | 441 | // Don't insert duplicates |
| 441 | - if ($count > 0) |
|
| 442 | - continue; |
|
| 442 | + if ($count > 0) { |
|
| 443 | + continue; |
|
| 444 | + } |
|
| 443 | 445 | |
| 444 | 446 | // Insert new background task |
| 445 | 447 | DB::insert( |