original_string: public function expired(\DateTime $date = null)
      {
          // Check if the token has an expiration date.
          if (!$this->expire) {
              return false;
          }
  
          $date = $date ?: new \DateTime('now', new \DateTimezone('UTC'));
  
          return ($date > $this->expire);
      }
code: public function expired(\DateTime $date = null)
      {
          // Check if the token has an expiration date.
          if (!$this->expire) {
              return false;
          }
  
          $date = $date ?: new \DateTime('now', new \DateTimezone('UTC'));
  
          return ($date > $this->expire);
      }
code_tokens: public function expired ( \ DateTime $ date = null ) { // Check if the token has an expiration date. if ( ! $ this -> expire ) { return false ; } $ date = $ date ? : new \ DateTime ( 'now' , new \ DateTimezone ( 'UTC' ) ) ; return ( $ date > $ this -> expire ) ; }
docstring: Checks whether the token has expired or is still valid.
  
  If the token has no expiration date, assumes the token doesn't expire.
  
  @param \DateTime $date
  (optional) The date to compare with the epiration date of the token.
  If not provided, the current time is used.
  
  @return bool
docstring_tokens: Checks whether the token has expired or is still valid .