Code Duplication    Length = 10-10 lines in 2 locations

src/Foundation/Composer.php 2 locations

@@ 17-26 (lines=10) @@
14
     *
15
     * @param Event $event
16
     */
17
    public static function postInstall(Event $event): void
18
    {
19
        $vendor = $event->getComposer()->getConfig()->get('vendor-dir');
20
21
        /** @noinspection PhpIncludeInspection */
22
        require_once $vendor.'/autoload.php';
23
24
        self::bootstrap($vendor);
25
        self::discoverAssets();
26
    }
27
28
    /**
29
     * Handle post-update event.
@@ 33-42 (lines=10) @@
30
     *
31
     * @param Event $event
32
     */
33
    public static function postUpdate(Event $event): void
34
    {
35
        $vendor = $event->getComposer()->getConfig()->get('vendor-dir');
36
37
        /** @noinspection PhpIncludeInspection */
38
        require_once $vendor.'/autoload.php';
39
40
        self::bootstrap($vendor);
41
        self::discoverAssets();
42
    }
43
44
    private static function bootstrap(string $vendor): void
45
    {