original_string: private function getUniqueKey(): string
      {
          do {
              try {
                  $isDuplicate = null;
                  $key = random_bytes($this->getOpt(self::OPT_SESSION_KEY_LENGTH));
  
                  // Ask for duplicate key from storage
                  $this->emit('duplicate-check', [$key, &$isDuplicate]);
  
              } catch (\Exception $e) {
                  throw new SessionException($e->getMessage(), SessionException::ERR_RANDOM_BYTES);
              }
          } while (isset($this->SESSION[$key]) || $isDuplicate === true);
  
          return $key;
      }
code: private function getUniqueKey(): string
      {
          do {
              try {
                  $isDuplicate = null;
                  $key = random_bytes($this->getOpt(self::OPT_SESSION_KEY_LENGTH));
  
                  // Ask for duplicate key from storage
                  $this->emit('duplicate-check', [$key, &$isDuplicate]);
  
              } catch (\Exception $e) {
                  throw new SessionException($e->getMessage(), SessionException::ERR_RANDOM_BYTES);
              }
          } while (isset($this->SESSION[$key]) || $isDuplicate === true);
  
          return $key;
      }
code_tokens: private function getUniqueKey ( ) : string { do { try { $ isDuplicate = null ; $ key = random_bytes ( $ this -> getOpt ( self :: OPT_SESSION_KEY_LENGTH ) ) ; // Ask for duplicate key from storage $ this -> emit ( 'duplicate-check' , [ $ key , & $ isDuplicate ] ) ; } catch ( \ Exception $ e ) { throw new SessionException ( $ e -> getMessage ( ) , SessionException :: ERR_RANDOM_BYTES ) ; } } while ( isset ( $ this -> SESSION [ $ key ] ) || $ isDuplicate === true ) ; return $ key ; }
docstring: Generate unique key
  @return string
  @throws SessionException
docstring_tokens: Generate unique key