Passed
Push — master ( 4e8f5f...d14653 )
by Darko
05:43
created
app/Models/MediaInfo.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -15,7 +15,7 @@
 block discarded – undo
15 15
     public static function addData($id, MediaInfoContainer $xmlArray): void
16 16
     {
17 17
         $mediainfoArray = $xmlArray->getGeneral();
18
-        if (! $mediainfoArray) {
18
+        if (!$mediainfoArray) {
19 19
             return;
20 20
         }
21 21
 
Please login to merge, or discard this patch.
routes/web.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -85,20 +85,20 @@  discard block
 block discarded – undo
85 85
 Route::post('login', [LoginController::class, 'login'])->name('login');
86 86
 Route::get('logout', [LoginController::class, 'logout'])->name('logout');
87 87
 
88
-Route::middleware('isVerified')->group(function () {
88
+Route::middleware('isVerified')->group(function() {
89 89
     Route::get('resetpassword', [ResetPasswordController::class, 'reset']);
90 90
     Route::post('resetpassword', [ResetPasswordController::class, 'reset']);
91 91
 
92 92
     Route::get('profile', [ProfileController::class, 'show']);
93 93
 
94
-    Route::prefix('browse')->group(function () {
94
+    Route::prefix('browse')->group(function() {
95 95
         Route::get('tags', [BrowseController::class, 'tags']);
96 96
         Route::get('group', [BrowseController::class, 'group']);
97 97
         Route::get('All', [BrowseController::class, 'index']);
98 98
         Route::get('{parentCategory}/{id?}', [BrowseController::class, 'show'])->middleware('clearance');
99 99
     });
100 100
 
101
-    Route::prefix('cart')->group(function () {
101
+    Route::prefix('cart')->group(function() {
102 102
         Route::get('index', [CartController::class, 'index']);
103 103
         Route::post('index', [CartController::class, 'index']);
104 104
         Route::get('add', [CartController::class, 'store']);
@@ -131,7 +131,7 @@  discard block
 block discarded – undo
131 131
 
132 132
     Route::post('failed', [FailedReleasesController::class, 'failed'])->name('failed');
133 133
 
134
-    Route::middleware('clearance')->group(function () {
134
+    Route::middleware('clearance')->group(function() {
135 135
         Route::get('Games', [GamesController::class, 'show'])->name('Games');
136 136
         Route::post('Games', [GamesController::class, 'show'])->name('Games');
137 137
 
@@ -226,7 +226,7 @@  discard block
 block discarded – undo
226 226
     Route::post('disable2fa', [PasswordSecurityController::class, 'disable2fa'])->name('disable2fa');
227 227
 });
228 228
 
229
-Route::middleware('role:Admin', '2fa')->prefix('admin')->group(function () {
229
+Route::middleware('role:Admin', '2fa')->prefix('admin')->group(function() {
230 230
     Route::get('index', [AdminPageController::class, 'index']);
231 231
     Route::get('anidb-delete/{id}', [AdminAnidbController::class, 'destroy']);
232 232
     Route::post('anidb-delete/{id}', [AdminAnidbController::class, 'destroy']);
@@ -345,12 +345,12 @@  discard block
 block discarded – undo
345 345
     Route::post('group-list-inactive', [AdminGroupController::class, 'inactive']);
346 346
 });
347 347
 
348
-Route::middleware('role_or_permission:Admin|Moderator|edit release')->prefix('admin')->group(function () {
348
+Route::middleware('role_or_permission:Admin|Moderator|edit release')->prefix('admin')->group(function() {
349 349
     Route::get('release-edit', [AdminReleasesController::class, 'edit']);
350 350
     Route::post('release-edit', [AdminReleasesController::class, 'edit']);
351 351
 });
352 352
 
353
-Route::post('2faVerify', function () {
353
+Route::post('2faVerify', function() {
354 354
     return redirect()->to(URL()->previous());
355 355
 })->name('2faVerify')->middleware('2fa');
356 356
 
Please login to merge, or discard this patch.
misc/testing/Releases/recategorize.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -10,7 +10,7 @@  discard block
 block discarded – undo
10 10
 
11 11
 $colorCli = new ColorCLI();
12 12
 
13
-if (! (isset($argv[1]) && ($argv[1] === 'all' || $argv[1] === 'misc' || preg_match('/\([\d, ]+\)/', $argv[1]) || is_numeric($argv[1])))) {
13
+if (!(isset($argv[1]) && ($argv[1] === 'all' || $argv[1] === 'misc' || preg_match('/\([\d, ]+\)/', $argv[1]) || is_numeric($argv[1])))) {
14 14
     $colorCli->error(
15 15
         "\nThis script will attempt to re-categorize releases and is useful if changes have been made to Category.php.\n"
16 16
         ."No updates will be done unless the category changes\n"
@@ -40,7 +40,7 @@  discard block
 block discarded – undo
40 40
     $timeStart = now();
41 41
     $chgCount = categorizeRelease($argv, true);
42 42
     $time = now()->diffInSeconds($timeStart, true);
43
-    if (! isset($argv[2])) {
43
+    if (!isset($argv[2])) {
44 44
         $colorCli->header('Finished re-categorizing '.number_format($chgCount).' releases in '.$time.' seconds, using the searchname.').PHP_EOL;
45 45
     } else {
46 46
         $colorCli->header('Finished re-categorizing in '.$time.' seconds , using the searchname.'.PHP_EOL
@@ -68,7 +68,7 @@  discard block
 block discarded – undo
68 68
     $consoleTools = new ConsoleTools();
69 69
     $relCount = $chgCount = 0;
70 70
     if ($total > 0) {
71
-        $query->chunk('100', function ($results) use ($update, $relCount, $chgCount) {
71
+        $query->chunk('100', function($results) use ($update, $relCount, $chgCount) {
72 72
             $cat = new Categorize();
73 73
             foreach ($results as $result) {
74 74
                 $catId = $cat->determineCategory($result->groups_id, $result->searchname, $result->fromname);
Please login to merge, or discard this patch.
app/Console/Commands/CleanNZB.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -37,7 +37,7 @@  discard block
 block discarded – undo
37 37
     public function handle(): void
38 38
     {
39 39
         // Check if any options are false
40
-        if (! $this->option('notindb') && ! $this->option('notondisk')) {
40
+        if (!$this->option('notindb') && !$this->option('notondisk')) {
41 41
             $this->error('You must specify at least one option. See: --help');
42 42
             exit();
43 43
         }
@@ -63,7 +63,7 @@  discard block
 block discarded – undo
63 63
             $guid = stristr($filePath->getFilename(), '.nzb.gz', true);
64 64
             if (File::isFile($filePath) && $guid) {
65 65
                 // If NZB file guid is not present in DB delete the file from disk
66
-                if (! $releases->whereGuid($guid)->exists()) {
66
+                if (!$releases->whereGuid($guid)->exists()) {
67 67
                     if ($delete) {
68 68
                         File::delete($filePath);
69 69
                     }
@@ -88,11 +88,11 @@  discard block
 block discarded – undo
88 88
         $total = Release::count();
89 89
         $this->alert("Total releases to check: $total");
90 90
 
91
-        Release::where('nzbstatus', 1)->chunkById((int) $this->option('chunksize'), function (Collection $releases) use ($delete, &$checked, &$deleted, $nzb, $rel) {
91
+        Release::where('nzbstatus', 1)->chunkById((int) $this->option('chunksize'), function(Collection $releases) use ($delete, &$checked, &$deleted, $nzb, $rel) {
92 92
             echo 'Total done: '.$checked."\r";
93 93
             foreach ($releases as $r) {
94 94
 
95
-                if (! $nzb->NZBPath($r->guid)) {
95
+                if (!$nzb->NZBPath($r->guid)) {
96 96
                     if ($delete) {
97 97
                         $rel->deleteSingle(['g' => $r->guid, 'i' => $r->id], $nzb, new ReleaseImage());
98 98
                     }
Please login to merge, or discard this patch.
app/Livewire/Forms/LoginForm.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -30,7 +30,7 @@  discard block
 block discarded – undo
30 30
     {
31 31
         $this->ensureIsNotRateLimited();
32 32
 
33
-        if (! Auth::attempt($this->only(['email', 'password']), $this->remember)) {
33
+        if (!Auth::attempt($this->only(['email', 'password']), $this->remember)) {
34 34
             RateLimiter::hit($this->throttleKey());
35 35
 
36 36
             throw ValidationException::withMessages([
@@ -46,7 +46,7 @@  discard block
 block discarded – undo
46 46
      */
47 47
     protected function ensureIsNotRateLimited(): void
48 48
     {
49
-        if (! RateLimiter::tooManyAttempts($this->throttleKey(), 5)) {
49
+        if (!RateLimiter::tooManyAttempts($this->throttleKey(), 5)) {
50 50
             return;
51 51
         }
52 52
 
Please login to merge, or discard this patch.
app/Http/Controllers/Auth/LoginController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -74,7 +74,7 @@
 block discarded – undo
74 74
             if ($user !== null) {
75 75
                 $rememberMe = $request->has('rememberme') && $request->input('rememberme') === 'on';
76 76
 
77
-                if (! $user->isVerified() || $user->isPendingVerification()) {
77
+                if (!$user->isVerified() || $user->isPendingVerification()) {
78 78
                     $request->session()->flash('message', 'You have not verified your email address!');
79 79
 
80 80
                     return redirect('login');
Please login to merge, or discard this patch.
Blacklight/ElasticSearchSiteSearch.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -277,8 +277,8 @@
 block discarded – undo
277 277
 
278 278
             // Execute a Scroll request and repeat
279 279
             $results = Elasticsearch::scroll([
280
-                'scroll_id' => $scroll_id,  //...using our previously obtained _scroll_id
281
-                'scroll' => '30s',        // and the same timeout window
280
+                'scroll_id' => $scroll_id, //...using our previously obtained _scroll_id
281
+                'scroll' => '30s', // and the same timeout window
282 282
             ]
283 283
             );
284 284
         }
Please login to merge, or discard this patch.
app/Http/Controllers/SearchController.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -65,7 +65,7 @@  discard block
 block discarded – undo
65 65
             foreach ($releases->getBrowseOrdering() as $orderType) {
66 66
                 $this->smarty->assign(
67 67
                     'orderby'.$orderType,
68
-                    url('/search?search='.htmlentities($searchString['searchname'], ENT_QUOTES | ENT_HTML5).'&t='.implode(',', $categoryID).'&ob='.$orderType));
68
+                    url('/search?search='.htmlentities($searchString['searchname'], ENT_QUOTES|ENT_HTML5).'&t='.implode(',', $categoryID).'&ob='.$orderType));
69 69
             }
70 70
 
71 71
             $rslt = $releases->search(
@@ -123,7 +123,7 @@  discard block
 block discarded – undo
123 123
         if ($searchType !== 'basic' && $request->missing('id') && $request->missing('subject') && $request->anyFilled(['searchadvr', 'searchadvsubject', 'searchadvfilename', 'searchadvposter'])) {
124 124
             $orderByString = '';
125 125
             foreach ($searchVars as $searchVarKey => $searchVar) {
126
-                $orderByString .= "&$searchVarKey=".htmlentities($searchVar, ENT_QUOTES | ENT_HTML5);
126
+                $orderByString .= "&$searchVarKey=".htmlentities($searchVar, ENT_QUOTES|ENT_HTML5);
127 127
             }
128 128
             $orderByString = ltrim($orderByString, '&');
129 129
 
Please login to merge, or discard this patch.