mirror of
https://github.com/NNTmux/newznab-tmux.git
synced 2026-08-29 00:01:21 +00:00
Apply fixes from StyleCI
[ci skip] [skip ci]
This commit is contained in:
@@ -5,14 +5,12 @@ namespace Blacklight;
|
||||
use App\Models\Release;
|
||||
use App\Models\Category;
|
||||
use App\Models\Settings;
|
||||
use Chumper\Zipper\Zipper;
|
||||
use App\Models\UsenetGroup;
|
||||
use Illuminate\Database\Eloquent\Collection;
|
||||
use Illuminate\Support\Arr;
|
||||
use Blacklight\utility\Utility;
|
||||
use Illuminate\Support\Facades\DB;
|
||||
use Illuminate\Support\Facades\File;
|
||||
use Illuminate\Support\Facades\Cache;
|
||||
use Illuminate\Database\Eloquent\Collection;
|
||||
|
||||
/**
|
||||
* Class Releases.
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
<?php
|
||||
|
||||
use App\Models\Release;
|
||||
use Blacklight\NZB;
|
||||
use Blacklight\utility\Utility;
|
||||
use Chumper\Zipper\Zipper;
|
||||
use Colors\Color;
|
||||
use Blacklight\NZB;
|
||||
use Blacklight\XXX;
|
||||
use GuzzleHttp\Client;
|
||||
use App\Models\Release;
|
||||
use Chumper\Zipper\Zipper;
|
||||
use Tuna\CloudflareMiddleware;
|
||||
use Blacklight\utility\Utility;
|
||||
use GuzzleHttp\Cookie\CookieJar;
|
||||
use GuzzleHttp\Cookie\SetCookie;
|
||||
use Illuminate\Support\Facades\DB;
|
||||
@@ -367,8 +367,8 @@ if (! function_exists('makeFieldLinks')) {
|
||||
{
|
||||
$nzb = new NZB();
|
||||
$zipped = new Zipper();
|
||||
$zippedFileName = now()->format('Ymdhis') . '.nzb.zip';
|
||||
$zippedFilePath = resource_path() . '/tmp/' . $zippedFileName;
|
||||
$zippedFileName = now()->format('Ymdhis').'.nzb.zip';
|
||||
$zippedFilePath = resource_path().'/tmp/'.$zippedFileName;
|
||||
|
||||
foreach ($guids as $guid) {
|
||||
$nzbPath = $nzb->NZBPath($guid);
|
||||
@@ -382,7 +382,7 @@ if (! function_exists('makeFieldLinks')) {
|
||||
if ($r) {
|
||||
$filename = $r['searchname'];
|
||||
}
|
||||
$zipped->make($zippedFilePath)->addString($filename . '.nzb', $nzbContents);
|
||||
$zipped->make($zippedFilePath)->addString($filename.'.nzb', $nzbContents);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -7,13 +7,13 @@ use App\Models\User;
|
||||
use App\Models\Release;
|
||||
use App\Models\UserDownload;
|
||||
use App\Models\UsersRelease;
|
||||
use Illuminate\Http\JsonResponse;
|
||||
use Illuminate\Http\Request;
|
||||
use Blacklight\utility\Utility;
|
||||
use Illuminate\Http\JsonResponse;
|
||||
use Illuminate\Support\Facades\Auth;
|
||||
use Illuminate\Support\Facades\File;
|
||||
use Symfony\Component\HttpFoundation\BinaryFileResponse;
|
||||
use Symfony\Component\HttpFoundation\StreamedResponse;
|
||||
use Symfony\Component\HttpFoundation\BinaryFileResponse;
|
||||
|
||||
class GetNzbController extends BasePageController
|
||||
{
|
||||
@@ -132,7 +132,7 @@ class GetNzbController extends BasePageController
|
||||
$headers += ['X-DNZB-RCode' => '200',
|
||||
'X-DNZB-RText' => 'OK, NZB content follows.', ];
|
||||
|
||||
return response()->streamDownload(function() use ($nzbPath) {
|
||||
return response()->streamDownload(function () use ($nzbPath) {
|
||||
readgzfile($nzbPath);
|
||||
}, $cleanName.'.nzb', $headers);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user