Cartalyst\Sentinel\Native\SentinelBootstrapper::createCheckpoints PHP Method

createCheckpoints() protected method

Create activation and throttling checkpoints.
protected createCheckpoints ( IlluminateActivationRepository $activations, IlluminateThrottleRepository $throttle, string $ipAddress ) : array
$activations Cartalyst\Sentinel\Activations\IlluminateActivationRepository
$throttle Cartalyst\Sentinel\Throttling\IlluminateThrottleRepository
$ipAddress string
return array
    protected function createCheckpoints(IlluminateActivationRepository $activations, IlluminateThrottleRepository $throttle, $ipAddress)
    {
        $activeCheckpoints = $this->config['checkpoints'];
        $activation = $this->createActivationCheckpoint($activations);
        $throttle = $this->createThrottleCheckpoint($throttle, $ipAddress);
        $checkpoints = [];
        foreach ($activeCheckpoints as $checkpoint) {
            if (!isset(${$checkpoint})) {
                throw new InvalidArgumentException("Invalid checkpoint [{$checkpoint}] given.");
            }
            $checkpoints[$checkpoint] = ${$checkpoint};
        }
        return $checkpoints;
    }