Scrutinizer GitHub App not installed

We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.

Install GitHub App

Code Duplication    Length = 18-18 lines in 2 locations

app/Plugins/Products/BackendController.php 2 locations

@@ 49-66 (lines=18) @@
46
     * @param string $plugin_name
47
     * @return mixed
48
     */
49
    public function install(string $plugin_name)
50
    {
51
        $plugin = $this->plugins->whereName($plugin_name);
52
53
        if ($plugin->enabled == false) {
54
            \DB::transaction(function () use ($plugin) {
55
                if ($plugin->handler instanceof Installable) {
56
                    $plugin->handler->install();
57
                }
58
59
                $plugin->enabled = true;
60
61
                $plugin->save();
62
            }, 5);
63
        }
64
65
        return response()->redirectToRoute('products.index');
66
    }
67
68
    /**
69
     * Steps required for the application uninstall.
@@ 75-92 (lines=18) @@
72
     * @param string $plugin_name
73
     * @return mixed
74
     */
75
    public function uninstall(string $plugin_name)
76
    {
77
        $plugin = $this->plugins->whereName($plugin_name);
78
79
        if ($plugin->enabled == true) {
80
            \DB::transaction(function () use ($plugin) {
81
                if ($plugin->handler instanceof Installable) {
82
                    $plugin->handler->uninstall();
83
                }
84
85
                $plugin->enabled = false;
86
87
                $plugin->save();
88
            }, 5);
89
        }
90
91
        return response()->redirectToRoute('products.index');
92
    }
93
}
94