Code Duplication    Length = 7-7 lines in 2 locations

src/WebSocketsServiceProvider.php 1 location

@@ 70-76 (lines=7) @@
67
            return new $class;
68
        });
69
70
        $this->app->singleton(StatisticsCollector::class, function () {
71
            $replicationMode = config('websockets.replication.mode', 'local');
72
73
            $class = config("websockets.replication.modes.{$replicationMode}.collector");
74
75
            return new $class;
76
        });
77
    }
78
79
    /**

src/Console/Commands/StartServer.php 1 location

@@ 107-113 (lines=7) @@
104
     */
105
    protected function configureManagers()
106
    {
107
        $this->laravel->singleton(ChannelManager::class, function () {
108
            $mode = config('websockets.replication.mode', 'local');
109
110
            $class = config("websockets.replication.modes.{$mode}.channel_manager");
111
112
            return new $class($this->loop);
113
        });
114
    }
115
116
    /**