@@ -106,7 +106,7 @@ discard block |
||
| 106 | 106 | Category::TV_ROOT, |
| 107 | 107 | Category::TV_OTHER, |
| 108 | 108 | $this->releases->showPasswords(), |
| 109 | - ! empty($limit) ? sprintf(' LIMIT %d OFFSET 0', min($limit, 100)) : '' |
|
| 109 | + !empty($limit) ? sprintf(' LIMIT %d OFFSET 0', min($limit, 100)) : '' |
|
| 110 | 110 | ); |
| 111 | 111 | |
| 112 | 112 | $expiresAt = now()->addMinutes(config('nntmux.cache_expiry_medium')); |
@@ -134,7 +134,7 @@ discard block |
||
| 134 | 134 | Category::MOVIE_ROOT, |
| 135 | 135 | Category::MOVIE_OTHER, |
| 136 | 136 | $this->releases->showPasswords(), |
| 137 | - ! empty($limit) ? sprintf(' LIMIT %d OFFSET 0', min($limit, 100)) : '' |
|
| 137 | + !empty($limit) ? sprintf(' LIMIT %d OFFSET 0', min($limit, 100)) : '' |
|
| 138 | 138 | ); |
| 139 | 139 | |
| 140 | 140 | $expiresAt = now()->addMinutes(config('nntmux.cache_expiry_medium')); |
@@ -158,7 +158,7 @@ discard block |
||
| 158 | 158 | { |
| 159 | 159 | $cacheKey = 'rss_trending_movies_48h'; |
| 160 | 160 | |
| 161 | - return Cache::remember($cacheKey, 3600, function () { |
|
| 161 | + return Cache::remember($cacheKey, 3600, function() { |
|
| 162 | 162 | $fortyEightHoursAgo = \Illuminate\Support\Carbon::now()->subHours(48); |
| 163 | 163 | |
| 164 | 164 | // First get the top 15 movies by download count |
@@ -218,7 +218,7 @@ discard block |
||
| 218 | 218 | { |
| 219 | 219 | $cacheKey = 'rss_trending_shows_48h'; |
| 220 | 220 | |
| 221 | - return Cache::remember($cacheKey, 3600, function () { |
|
| 221 | + return Cache::remember($cacheKey, 3600, function() { |
|
| 222 | 222 | $fortyEightHoursAgo = \Illuminate\Support\Carbon::now()->subHours(48); |
| 223 | 223 | |
| 224 | 224 | // First get the top 15 TV shows by download count |
@@ -37,11 +37,11 @@ |
||
| 37 | 37 | $backfill = new Backfill(['NNTP' => $nntp]); |
| 38 | 38 | |
| 39 | 39 | match (true) { |
| 40 | - $mode === 'all' && ! isset($quantity) => $backfill->backfillAllGroups(), |
|
| 40 | + $mode === 'all' && !isset($quantity) => $backfill->backfillAllGroups(), |
|
| 41 | 41 | $mode === 'alph' && is_numeric($quantity) => $backfill->backfillAllGroups('', (int) $quantity, 'normal'), |
| 42 | 42 | $mode === 'date' && is_numeric($quantity) => $backfill->backfillAllGroups('', (int) $quantity, 'date'), |
| 43 | 43 | $mode === 'safe' && is_numeric($quantity) => $backfill->safeBackfill((int) $quantity), |
| 44 | - preg_match('/^alt\.binaries\..+$/i', $mode) && ! isset($quantity) => $backfill->backfillAllGroups($mode), |
|
| 44 | + preg_match('/^alt\.binaries\..+$/i', $mode) && !isset($quantity) => $backfill->backfillAllGroups($mode), |
|
| 45 | 45 | preg_match('/^alt\.binaries\..+$/i', $mode) && is_numeric($quantity) => $backfill->backfillAllGroups($mode, (int) $quantity), |
| 46 | 46 | default => throw new \Exception($this->getHelpText()), |
| 47 | 47 | }; |
@@ -28,7 +28,7 @@ |
||
| 28 | 28 | { |
| 29 | 29 | $limit = $this->argument('limit'); |
| 30 | 30 | |
| 31 | - if ($limit !== null && ! is_numeric($limit)) { |
|
| 31 | + if ($limit !== null && !is_numeric($limit)) { |
|
| 32 | 32 | $this->error('Limit must be a number'); |
| 33 | 33 | |
| 34 | 34 | return Command::FAILURE; |
@@ -36,7 +36,7 @@ |
||
| 36 | 36 | { |
| 37 | 37 | $groupId = $this->argument('groupId'); |
| 38 | 38 | |
| 39 | - if (! is_numeric($groupId)) { |
|
| 39 | + if (!is_numeric($groupId)) { |
|
| 40 | 40 | $this->error('Group ID must be numeric.'); |
| 41 | 41 | |
| 42 | 42 | return self::FAILURE; |
@@ -45,15 +45,15 @@ |
||
| 45 | 45 | $this->sessionManager = new TmuxSessionManager($sessionName); |
| 46 | 46 | |
| 47 | 47 | // Check if session exists |
| 48 | - if (! $this->sessionManager->sessionExists()) { |
|
| 48 | + if (!$this->sessionManager->sessionExists()) { |
|
| 49 | 49 | $this->warn("⚠️ Session '{$sessionName}' is not running"); |
| 50 | 50 | |
| 51 | 51 | return Command::SUCCESS; |
| 52 | 52 | } |
| 53 | 53 | |
| 54 | 54 | // Confirm unless forced |
| 55 | - if (! $this->option('force')) { |
|
| 56 | - if (! $this->confirm("Stop tmux session '{$sessionName}'?", true)) { |
|
| 55 | + if (!$this->option('force')) { |
|
| 56 | + if (!$this->confirm("Stop tmux session '{$sessionName}'?", true)) { |
|
| 57 | 57 | $this->info('Cancelled'); |
| 58 | 58 | |
| 59 | 59 | return Command::SUCCESS; |
@@ -29,7 +29,7 @@ |
||
| 29 | 29 | { |
| 30 | 30 | $type = $this->argument('type'); |
| 31 | 31 | |
| 32 | - if (! \in_array($type, ['backfill', 'binaries'], true)) { |
|
| 32 | + if (!\in_array($type, ['backfill', 'binaries'], true)) { |
|
| 33 | 33 | $this->error('Type must be either: binaries or backfill'); |
| 34 | 34 | $this->line(''); |
| 35 | 35 | $this->line('binaries => Do Safe Binaries update'); |
@@ -97,7 +97,7 @@ |
||
| 97 | 97 | $this->colorCli->header('Resetting expired collections. This may take some time...'); |
| 98 | 98 | |
| 99 | 99 | try { |
| 100 | - DB::transaction(function () use ($delayTime) { |
|
| 100 | + DB::transaction(function() use ($delayTime) { |
|
| 101 | 101 | Collection::query() |
| 102 | 102 | ->where('dateadded', '<', now()->subHours($delayTime)) |
| 103 | 103 | ->update(['dateadded' => now()]); |
@@ -40,7 +40,7 @@ |
||
| 40 | 40 | $firstArticle = (int) $this->argument('first'); |
| 41 | 41 | $lastArticle = (int) $this->argument('last'); |
| 42 | 42 | |
| 43 | - if (! \in_array($mode, ['binaries', 'backfill'], true)) { |
|
| 43 | + if (!\in_array($mode, ['binaries', 'backfill'], true)) { |
|
| 44 | 44 | $this->error('Mode must be either "binaries" or "backfill".'); |
| 45 | 45 | |
| 46 | 46 | return self::FAILURE; |
@@ -50,7 +50,7 @@ |
||
| 50 | 50 | $echoArg = $this->argument('echo'); |
| 51 | 51 | $echo = ($echoArg === null || $echoArg === 'true'); |
| 52 | 52 | |
| 53 | - if (! array_key_exists($type, $this->validTypes)) { |
|
| 53 | + if (!array_key_exists($type, $this->validTypes)) { |
|
| 54 | 54 | $this->error("Invalid type: {$type}"); |
| 55 | 55 | $this->showHelp(); |
| 56 | 56 | |