WordPress\AiClient\Providers\OpenAiCompatibleImplementation
AbstractOpenAiCompatibleModelMetadataDirectory::throwIfNotSuccessful
Throws an exception if the response is not successful.
Метод класса: AbstractOpenAiCompatibleModelMetadataDirectory{}
Хуков нет.
Возвращает
null. Ничего (null).
Использование
// protected - в коде основоного (родительского) или дочернего класса $result = $this->throwIfNotSuccessful( $response ): void;
- $response(Response) (обязательный)
- The HTTP response to check.
Список изменений
| С версии 0.1.0 | Введена. |
Код AbstractOpenAiCompatibleModelMetadataDirectory::throwIfNotSuccessful() AbstractOpenAiCompatibleModelMetadataDirectory::throwIfNotSuccessful WP 7.1.2
protected function throwIfNotSuccessful(Response $response): void
{
/*
* While this method only calls the utility method, it's important to have it here as a protected method so
* that child classes can override it if needed.
*/
ResponseUtil::throwIfNotSuccessful($response);
}