Files

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

26 lines
568 B
PHP
Raw Permalink Normal View History

<?php
namespace App\Http\Controllers;
use App\Models\Plugin;
2024-08-15 15:26:47 -05:00
use LibreNMS\Interfaces\Plugins\PluginManagerInterface;
class PluginAdminController extends Controller
{
2024-08-15 15:26:47 -05:00
public function __invoke(PluginManagerInterface $manager): \Illuminate\Contracts\View\View
{
// legacy v1 plugins
\LibreNMS\Plugins::scanNew();
\LibreNMS\Plugins::scanRemoved();
// v2 cleanup
$manager->cleanupPlugins();
$plugins = Plugin::get();
return view('plugins.admin', [
'plugins' => $plugins,
]);
}
}