original_string: public function destroy()
      {
          if ($this->_hasSession() && !$this->started()) {
              $this->start();
          }
  
          if (!$this->_isCLI && session_status() === \PHP_SESSION_ACTIVE) {
              session_destroy();
          }
  
          $_SESSION = [];
          $this->_started = false;
      }
code: public function destroy()
      {
          if ($this->_hasSession() && !$this->started()) {
              $this->start();
          }
  
          if (!$this->_isCLI && session_status() === \PHP_SESSION_ACTIVE) {
              session_destroy();
          }
  
          $_SESSION = [];
          $this->_started = false;
      }
code_tokens: public function destroy ( ) { if ( $ this -> _hasSession ( ) && ! $ this -> started ( ) ) { $ this -> start ( ) ; } if ( ! $ this -> _isCLI && session_status ( ) === \ PHP_SESSION_ACTIVE ) { session_destroy ( ) ; } $ _SESSION = [ ] ; $ this -> _started = false ; }
docstring: Helper method to destroy invalid sessions.
  
  @return void
docstring_tokens: Helper method to destroy invalid sessions .