src/StaticApplicationAbstract.php
public function run()
    {
        $isConsole = Reaction::isConsoleApp();
        if (!$isConsole && isset($this->http)) {
            echo sprintf("Running server on 'http://%s:%d'\n", $this->hostname, $this->port);
        }
        $this->initPromise = $this->loadComponents()->always(
            function() use ($isConsole) {
                if (!$isConsole) {
                    Reaction::info('StaticApplication initialized');
                }
                $this->initialized = true;
                return true;
            }
        );
        //Kickstart loop if it is not external
        if (!$this->loopIsExternal) {
            $this->loop->run();
        }
    }
public function run()
    {
        $isConsole = Reaction::isConsoleApp();
        if (!$isConsole && isset($this->http)) {
            echo sprintf("Running server on 'http://%s:%d'\n", $this->hostname, $this->port);
        }
        $this->initPromise = $this->loadComponents()->always(
            function() use ($isConsole) {
                if (!$isConsole) {
                    Reaction::info('StaticApplication initialized');
                }
                $this->initialized = true;
                return true;
            }
        );
        //Kickstart loop if it is not external
        if (!$this->loopIsExternal) {
            $this->loop->run();
        }
    }
Run application