public function getFirstProcess()
    {
        $firstProcess = null;
        foreach ($this->process as $process) {
            if ($this->isRunning() && ! $process->isRunning()) {
                $this->detach($process);
                continue;
            }

            if (null !== $firstProcess) {
                continue;
            }
            $firstProcess = $process;
        }

        return $firstProcess;
    }