src/LERN.php
protected function buildRecorder(Recorder $recorder = null)
    {
        $class = config('lern.record.class');
        $class = !empty($class) ? $class : Recorder::class;
        if (empty($recorder)) {
            $recorder = new $class();
        }
        if ($recorder instanceof Recorder) {
            return $recorder;
        } else {
            throw new RecorderFailedException("LERN was expecting an instance of ".Recorder::class);
        }
    }
protected function buildRecorder(Recorder $recorder = null)
    {
        $class = config('lern.record.class');
        $class = !empty($class) ? $class : Recorder::class;
        if (empty($recorder)) {
            $recorder = new $class();
        }
        if ($recorder instanceof Recorder) {
            return $recorder;
        } else {
            throw new RecorderFailedException("LERN was expecting an instance of ".Recorder::class);
        }
    }
protected function buildRecorder ( Recorder $ recorder = null ) { $ class = config ( 'lern.record.class' ) ; $ class = ! empty ( $ class ) ? $ class : Recorder :: class ; if ( empty ( $ recorder ) ) { $ recorder = new $ class ( ) ; } if ( $ recorder instanceof Recorder ) { return $ recorder ; } else { throw new RecorderFailedException ( "LERN was expecting an instance of " . Recorder :: class ) ; } }
Constructs a Recorder

@param Recorder $recorder
@return Recorder
Constructs a Recorder