protected function _check_php_session()
{
// Get the auth_source config item
$key = $this->config->item('auth_source');
// If falsy, then the user isn't logged in
if (!$this->session->userdata($key)) {
// Display an error response
$this->response([$this->config->item('rest_status_field_name') => FALSE, $this->config->item('rest_message_field_name') => $this->lang->line('text_rest_unauthorized')], self::HTTP_UNAUTHORIZED);
}
}