kenhuuu commented on code in PR #3402:
URL: https://github.com/apache/tinkerpop/pull/3402#discussion_r3204970604
##########
gremlin-js/gremlin-javascript/lib/driver/request-message.ts:
##########
@@ -128,16 +131,24 @@ export class Builder {
}
addBinding(key: string, value: any): Builder {
+ if (this.bindingsString) throw new Error('Cannot mix addBinding() with
addBindingsString().');
Object.assign(this.bindings, {[key]: value})
return this;
}
addBindings(otherBindings: object): Builder {
if (!otherBindings) throw new Error('bindings argument cannot be null.');
+ if (this.bindingsString) throw new Error('Cannot mix addBindings() with
addBindingsString().');
Object.assign(this.bindings, otherBindings)
return this;
}
+ addBindingsString(bindingsString: string): Builder {
Review Comment:
Yea I think that should get commented so I'll update that. Regarding
allowing it to only be called once, my opinion is that its not necessary for
now. The documentation will say "last one wins".
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]