Passed
Push — master ( 9f15d2...3a106b )
by Darko
10:30
created
app/Http/Controllers/Admin/AdminCategoryRegexesController.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@  discard block
 block discarded – undo
19 19
 
20 20
         $meta_title = $title = 'Category Regex List';
21 21
 
22
-        $group = $request->has('group') && ! empty($request->input('group')) ? $request->input('group') : '';
22
+        $group = $request->has('group') && !empty($request->input('group')) ? $request->input('group') : '';
23 23
         $regex = $regexes->getRegex($group);
24 24
 
25 25
         $this->viewData = array_merge($this->viewData, [
@@ -70,7 +70,7 @@  discard block
 block discarded – undo
70 70
                     break;
71 71
                 }
72 72
 
73
-                if (! is_numeric($request->input('ordinal')) || $request->input('ordinal') < 0) {
73
+                if (!is_numeric($request->input('ordinal')) || $request->input('ordinal') < 0) {
74 74
                     $error = 'Ordinal must be a number, 0 or higher.';
75 75
                     break;
76 76
                 }
Please login to merge, or discard this patch.
app/Http/Controllers/Admin/AdminCategoryController.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -57,9 +57,9 @@  discard block
 block discarded – undo
57 57
 
58 58
                 $category->title = $request->input('title');
59 59
                 $category->root_categories_id = $request->input('root_categories_id') ?: null;
60
-                $category->status = Category::STATUS_ACTIVE;  // Always active
60
+                $category->status = Category::STATUS_ACTIVE; // Always active
61 61
                 $category->description = $request->input('description');
62
-                $category->disablepreview = 0;  // Always enabled
62
+                $category->disablepreview = 0; // Always enabled
63 63
                 $category->minsizetoformrelease = 0;
64 64
                 $category->maxsizetoformrelease = 0;
65 65
                 $category->save();
@@ -102,9 +102,9 @@  discard block
 block discarded – undo
102 102
                 $category = Category::find($request->input('id'));
103 103
                 if ($category) {
104 104
                     $category->root_categories_id = $request->input('root_categories_id') ?: null;
105
-                    $category->status = Category::STATUS_ACTIVE;  // Always active
105
+                    $category->status = Category::STATUS_ACTIVE; // Always active
106 106
                     $category->description = $request->input('description');
107
-                    $category->disablepreview = 0;  // Always enabled
107
+                    $category->disablepreview = 0; // Always enabled
108 108
                     $category->minsizetoformrelease = 0;
109 109
                     $category->maxsizetoformrelease = 0;
110 110
                     $category->save();
Please login to merge, or discard this patch.
app/Http/Controllers/Admin/AdminGroupController.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -30,7 +30,7 @@  discard block
 block discarded – undo
30 30
         $groupmsglist = '';
31 31
 
32 32
         if ($action === 'submit') {
33
-            if ($request->has('groupfilter') && ! empty($request->input('groupfilter'))) {
33
+            if ($request->has('groupfilter') && !empty($request->input('groupfilter'))) {
34 34
                 $groupmsglist = UsenetGroup::addBulk($request->input('groupfilter'), $request->input('active'), $request->input('backfill'));
35 35
             }
36 36
         }
@@ -101,11 +101,11 @@  discard block
 block discarded – undo
101 101
     public function active(Request $request)
102 102
     {
103 103
         $gname = '';
104
-        if (! empty($request->input('groupname'))) {
104
+        if (!empty($request->input('groupname'))) {
105 105
             $gname = $request->input('groupname');
106 106
         }
107 107
 
108
-        $groupname = ! empty($request->input('groupname')) ? $request->input('groupname') : '';
108
+        $groupname = !empty($request->input('groupname')) ? $request->input('groupname') : '';
109 109
         $grouplist = UsenetGroup::getGroupsRange($gname, true);
110 110
         $title = 'Active Groups';
111 111
 
@@ -118,11 +118,11 @@  discard block
 block discarded – undo
118 118
     public function inactive(Request $request)
119 119
     {
120 120
         $gname = '';
121
-        if (! empty($request->input('groupname'))) {
121
+        if (!empty($request->input('groupname'))) {
122 122
             $gname = $request->input('groupname');
123 123
         }
124 124
 
125
-        $groupname = ! empty($request->input('groupname')) ? $request->input('groupname') : '';
125
+        $groupname = !empty($request->input('groupname')) ? $request->input('groupname') : '';
126 126
         $grouplist = UsenetGroup::getGroupsRange($gname, false);
127 127
         $title = 'Inactive Groups';
128 128
 
Please login to merge, or discard this patch.
app/Http/Controllers/Admin/AdminBookController.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -43,7 +43,7 @@  discard block
 block discarded – undo
43 43
             $id = $request->input('id');
44 44
             $b = $book->getBookInfo($id);
45 45
 
46
-            if (! $b) {
46
+            if (!$b) {
47 47
                 abort(404);
48 48
             }
49 49
 
@@ -54,13 +54,13 @@  discard block
 block discarded – undo
54 54
                     if ($request->hasFile('cover') && $request->file('cover')->isValid()) {
55 55
                         $uploadedFile = $request->file('cover');
56 56
                         $file_info = getimagesize($uploadedFile->getRealPath());
57
-                        if (! empty($file_info)) {
57
+                        if (!empty($file_info)) {
58 58
                             $uploadedFile->move(storage_path('covers/book'), $id.'.jpg');
59 59
                         }
60 60
                     }
61 61
 
62 62
                     $hasCover = file_exists($coverLoc) ? 1 : 0;
63
-                    $publishdate = (empty($request->input('publishdate')) || ! strtotime($request->input('publishdate')))
63
+                    $publishdate = (empty($request->input('publishdate')) || !strtotime($request->input('publishdate')))
64 64
                         ? ($b['publishdate'] ?? null)
65 65
                         : Carbon::parse($request->input('publishdate'))->timestamp;
66 66
 
Please login to merge, or discard this patch.
app/Http/Controllers/Admin/AdminSiteController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -93,7 +93,7 @@
 block discarded – undo
93 93
         // convert from a string array to an int array
94 94
         $books_selected = array_map(fn ($value) => (int) $value, $books_selected);
95 95
 
96
-        $compress_headers_warning = ! str_contains(config('settings.nntp_server'), 'astra') ? 'compress_headers_warning' : '';
96
+        $compress_headers_warning = !str_contains(config('settings.nntp_server'), 'astra') ? 'compress_headers_warning' : '';
97 97
 
98 98
         $this->viewData = array_merge($this->viewData, [
99 99
             'site' => $site,
Please login to merge, or discard this patch.
app/Http/Controllers/Admin/AdminCollectionRegexesController.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@  discard block
 block discarded – undo
19 19
 
20 20
         $meta_title = $title = 'Collections Regex List';
21 21
 
22
-        $group = ($request->has('group') && ! empty($request->input('group')) ? $request->input('group') : '');
22
+        $group = ($request->has('group') && !empty($request->input('group')) ? $request->input('group') : '');
23 23
         $regex = $regexes->getRegex($group);
24 24
 
25 25
         $this->viewData = array_merge($this->viewData, [
@@ -61,7 +61,7 @@  discard block
 block discarded – undo
61 61
                     $request->merge(['description' => '']);
62 62
                 }
63 63
 
64
-                if (! is_numeric($request->input('ordinal')) || $request->input('ordinal') < 0) {
64
+                if (!is_numeric($request->input('ordinal')) || $request->input('ordinal') < 0) {
65 65
                     $error = 'Ordinal must be a number, 0 or higher.';
66 66
                     break;
67 67
                 }
@@ -106,8 +106,8 @@  discard block
 block discarded – undo
106 106
         $this->setAdminPrefs();
107 107
         $meta_title = $title = 'Collections Regex Test';
108 108
 
109
-        $group = trim($request->has('group') && ! empty($request->input('group')) ? $request->input('group') : '');
110
-        $regex = trim($request->has('regex') && ! empty($request->input('regex')) ? $request->input('regex') : '');
109
+        $group = trim($request->has('group') && !empty($request->input('group')) ? $request->input('group') : '');
110
+        $regex = trim($request->has('regex') && !empty($request->input('regex')) ? $request->input('regex') : '');
111 111
         $limit = ($request->has('limit') && is_numeric($request->input('limit')) ? $request->input('limit') : 50);
112 112
 
113 113
         $data = null;
Please login to merge, or discard this patch.
app/Http/Controllers/Admin/AdminGameController.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -22,7 +22,7 @@  discard block
 block discarded – undo
22 22
         // Get search parameter
23 23
         $search = $request->input('gamesearch', '');
24 24
 
25
-        if (! empty($search)) {
25
+        if (!empty($search)) {
26 26
             $gamelist = $game->getRange($search);
27 27
             $lastSearch = $search;
28 28
         } else {
@@ -49,7 +49,7 @@  discard block
 block discarded – undo
49 49
             $id = $request->input('id');
50 50
             $game = $games->getGamesInfoById($id);
51 51
 
52
-            if (! $game) {
52
+            if (!$game) {
53 53
                 abort(404, 'Game not found');
54 54
             }
55 55
 
@@ -60,13 +60,13 @@  discard block
 block discarded – undo
60 60
                     if ($request->hasFile('cover') && $request->file('cover')->isValid()) {
61 61
                         $file = $request->file('cover');
62 62
                         $file_info = getimagesize($file->getPathname());
63
-                        if (! empty($file_info)) {
63
+                        if (!empty($file_info)) {
64 64
                             $file->move(storage_path('covers/games/'), $id.'.jpg');
65 65
                         }
66 66
                     }
67 67
 
68 68
                     $cover = file_exists($coverLoc) ? 1 : 0;
69
-                    $releasedate = (empty($request->input('releasedate')) || ! strtotime($request->input('releasedate')))
69
+                    $releasedate = (empty($request->input('releasedate')) || !strtotime($request->input('releasedate')))
70 70
                         ? $game['releasedate']
71 71
                         : Carbon::parse($request->input('releasedate'))->timestamp;
72 72
 
Please login to merge, or discard this patch.
app/Http/Controllers/Admin/AdminMovieController.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -35,21 +35,21 @@  discard block
 block discarded – undo
35 35
      */
36 36
     public function create(Request $request)
37 37
     {
38
-        if (! \defined('STDOUT')) {
38
+        if (!\defined('STDOUT')) {
39 39
             \define('STDOUT', fopen('php://stdout', 'wb'));
40 40
         }
41 41
 
42 42
         $title = 'Movie Add';
43 43
 
44 44
         // If no ID provided, show the add form
45
-        if (! $request->has('id')) {
45
+        if (!$request->has('id')) {
46 46
             return view('admin.movies.add', compact('title'));
47 47
         }
48 48
 
49 49
         // Validate the IMDB ID
50 50
         $id = $request->input('id');
51 51
 
52
-        if (! is_numeric($id)) {
52
+        if (!is_numeric($id)) {
53 53
             return redirect()->back()
54 54
                 ->with('error', 'Invalid IMDB ID. Please enter only numeric digits (without the "tt" prefix).')
55 55
                 ->withInput();
@@ -105,7 +105,7 @@  discard block
 block discarded – undo
105 105
         $title = 'Movie Edit';
106 106
 
107 107
         // Check if ID is provided
108
-        if (! $request->has('id')) {
108
+        if (!$request->has('id')) {
109 109
             return redirect()->to('admin/movie-list')
110 110
                 ->with('error', 'No movie ID provided.');
111 111
         }
@@ -121,7 +121,7 @@  discard block
 block discarded – undo
121 121
         // Handle update from TMDB
122 122
         if ($request->has('update') && (int) $request->input('update') === 1) {
123 123
             try {
124
-                if (! \defined('STDOUT')) {
124
+                if (!\defined('STDOUT')) {
125 125
                     \define('STDOUT', fopen('php://stdout', 'wb'));
126 126
                 }
127 127
 
@@ -149,7 +149,7 @@  discard block
 block discarded – undo
149 149
                 $backdropLoc = public_path('covers/movies/'.$id.'-backdrop.jpg');
150 150
 
151 151
                 // Ensure directory exists
152
-                if (! file_exists(public_path('covers/movies'))) {
152
+                if (!file_exists(public_path('covers/movies'))) {
153 153
                     mkdir(public_path('covers/movies'), 0755, true);
154 154
                 }
155 155
 
Please login to merge, or discard this patch.
app/Http/Controllers/MusicController.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -49,9 +49,9 @@
 block discarded – undo
49 49
         $rslt = $music->getMusicRange($page, $catarray, $offset, config('nntmux.items_per_cover_page'), $orderby, $this->userdata->categoryexclusions);
50 50
         $results = $this->paginate($rslt ?? [], $rslt[0]->_totalcount ?? 0, config('nntmux.items_per_cover_page'), $page, $request->url(), $request->query());
51 51
 
52
-        $artist = ($request->has('artist') && ! empty($request->input('artist'))) ? stripslashes($request->input('artist')) : '';
52
+        $artist = ($request->has('artist') && !empty($request->input('artist'))) ? stripslashes($request->input('artist')) : '';
53 53
 
54
-        $title = ($request->has('title') && ! empty($request->input('title'))) ? stripslashes($request->input('title')) : '';
54
+        $title = ($request->has('title') && !empty($request->input('title'))) ? stripslashes($request->input('title')) : '';
55 55
 
56 56
         $genres = $gen->getGenres(Genres::MUSIC_TYPE, true);
57 57
         $tmpgnr = [];
Please login to merge, or discard this patch.