NNTmux /
newznab-tmux
| 1 | <?php |
||
| 2 | |||
| 3 | namespace App\Http\Controllers; |
||
| 4 | |||
| 5 | use App\Models\Category; |
||
| 6 | use Illuminate\Http\Request; |
||
| 7 | use Illuminate\View\View; |
||
| 8 | |||
| 9 | class ApiHelpController extends BasePageController |
||
| 10 | { |
||
| 11 | public function __construct(Request $request) |
||
| 12 | { |
||
| 13 | parent::__construct($request); |
||
|
0 ignored issues
–
show
|
|||
| 14 | } |
||
| 15 | |||
| 16 | /** |
||
| 17 | * @throws \Exception |
||
| 18 | */ |
||
| 19 | public function index(): View |
||
| 20 | { |
||
| 21 | $this->setAdminPrefs(); |
||
| 22 | |||
| 23 | $this->viewData['title'] = 'Api Help'; |
||
| 24 | $this->viewData['meta_title'] = 'Api Help Topics'; |
||
| 25 | $this->viewData['meta_keywords'] = 'view,nzb,api,details,help,json,rss,atom'; |
||
| 26 | $this->viewData['meta_description'] = 'View description of the site Nzb Api.'; |
||
| 27 | $this->viewData['catClass'] = Category::class; |
||
| 28 | |||
| 29 | return view('api.apidesc', $this->viewData); |
||
| 30 | } |
||
| 31 | |||
| 32 | /** |
||
| 33 | * @throws \Exception |
||
| 34 | */ |
||
| 35 | public function apiv2(): View |
||
| 36 | { |
||
| 37 | $this->setAdminPrefs(); |
||
| 38 | |||
| 39 | $this->viewData['title'] = 'Api V2 Help'; |
||
| 40 | $this->viewData['meta_title'] = 'Api V2 Help Topics'; |
||
| 41 | $this->viewData['meta_keywords'] = 'view,nzb,api,details,help,json,rss,atom'; |
||
| 42 | $this->viewData['meta_description'] = 'View description of the site Nzb version 2 Api.'; |
||
| 43 | $this->viewData['catClass'] = Category::class; |
||
| 44 | |||
| 45 | return view('api.apiv2desc', $this->viewData); |
||
| 46 | } |
||
| 47 | } |
||
| 48 |
This check compares calls to functions or methods with their respective definitions. If the call has more arguments than are defined, it raises an issue.
If a function is defined several times with a different number of parameters, the check may pick up the wrong definition and report false positives. One codebase where this has been known to happen is Wordpress. Please note the @ignore annotation hint above.