fix: getResponseModel

This commit is contained in:
Danny Avila 2024-09-03 18:50:11 -04:00
parent dd90907a18
commit 43b280fb5d
No known key found for this signature in database
GPG key ID: 2DD9CC89B9B50364

View file

@ -71,7 +71,7 @@ class BaseClient {
* @returns {string}
*/
getResponseModel() {
if (this.options.agent.id && isAgentsEndpoint(this.options.endpoint)) {
if (isAgentsEndpoint(this.options.endpoint) && this.options.agent && this.options.agent.id) {
return this.options.agent.id;
}