original_string: public function validate(JwtAuthValidateEvent $event) {
      $token = $event->getToken();
  
      $uid = $token->getClaim('webid');
      $name = $token->getClaim('sub');
      $roles = $token->getClaim('roles');
      $url = $token->getClaim('iss');
      if ($uid === NULL || $name === NULL || $roles === NULL || $url === NULL) {
        $event->invalidate("Expected data missing from payload.");
        return;
      }
  
      $user = $this->userStorage->load($uid);
      if ($user === NULL) {
        $event->invalidate("Specified UID does not exist.");
      }
      elseif ($user->getAccountName() !== $name) {
        $event->invalidate("Account name does not match.");
      }
    }
code: public function validate(JwtAuthValidateEvent $event) {
      $token = $event->getToken();
  
      $uid = $token->getClaim('webid');
      $name = $token->getClaim('sub');
      $roles = $token->getClaim('roles');
      $url = $token->getClaim('iss');
      if ($uid === NULL || $name === NULL || $roles === NULL || $url === NULL) {
        $event->invalidate("Expected data missing from payload.");
        return;
      }
  
      $user = $this->userStorage->load($uid);
      if ($user === NULL) {
        $event->invalidate("Specified UID does not exist.");
      }
      elseif ($user->getAccountName() !== $name) {
        $event->invalidate("Account name does not match.");
      }
    }
code_tokens: public function validate ( JwtAuthValidateEvent $ event ) { $ token = $ event -> getToken ( ) ; $ uid = $ token -> getClaim ( 'webid' ) ; $ name = $ token -> getClaim ( 'sub' ) ; $ roles = $ token -> getClaim ( 'roles' ) ; $ url = $ token -> getClaim ( 'iss' ) ; if ( $ uid === NULL || $ name === NULL || $ roles === NULL || $ url === NULL ) { $ event -> invalidate ( "Expected data missing from payload." ) ; return ; } $ user = $ this -> userStorage -> load ( $ uid ) ; if ( $ user === NULL ) { $ event -> invalidate ( "Specified UID does not exist." ) ; } elseif ( $ user -> getAccountName ( ) !== $ name ) { $ event -> invalidate ( "Account name does not match." ) ; } }
docstring: Validates that the Islandora data is present in the JWT.
  
  @param \Drupal\jwt\Authentication\Event\JwtAuthValidateEvent $event
  A JwtAuth event.
docstring_tokens: Validates that the Islandora data is present in the JWT .