Skip to content

Commit 17be0da

Browse files
committed
Update return docs to reflect what is being returned
1 parent 752ef3e commit 17be0da

File tree

1 file changed

+11
-15
lines changed

1 file changed

+11
-15
lines changed

src/ClientBuilder.js

Lines changed: 11 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ class ClientBuilder {
6060

6161
/**
6262
* @param retries The maximum number of times to retry sending the request to the API. (Default is 5)
63-
* @return Returns <b>this</b> to accommodate method chaining.
63+
* @return ClientBuilder <b>this</b> to accommodate method chaining.
6464
*/
6565
withMaxRetries(retries) {
6666
this.maxRetries = retries;
@@ -70,7 +70,7 @@ class ClientBuilder {
7070
/**
7171
* @param timeout The maximum time (in milliseconds) to wait for a connection, and also to wait for <br>
7272
* the response to be read. (Default is 10000)
73-
* @return Returns <b>this</b> to accommodate method chaining.
73+
* @return ClientBuilder <b>this</b> to accommodate method chaining.
7474
*/
7575
withMaxTimeout(timeout) {
7676
this.maxTimeout = timeout;
@@ -79,7 +79,7 @@ class ClientBuilder {
7979

8080
/**
8181
* @param sender Default is a series of nested senders. See <b>buildSender()</b>.
82-
* @return Returns <b>this</b> to accommodate method chaining.
82+
* @return ClientBuilder <b>this</b> to accommodate method chaining.
8383
*/
8484
withSender(sender) {
8585
this.httpSender = sender;
@@ -89,7 +89,7 @@ class ClientBuilder {
8989
/**
9090
* This may be useful when using a local installation of the Smarty APIs.
9191
* @param url Defaults to the URL for the API corresponding to the <b>Client</b> object being built.
92-
* @return Returns <b>this</b> to accommodate method chaining.
92+
* @return ClientBuilder <b>this</b> to accommodate method chaining.
9393
*/
9494
withBaseUrl(url) {
9595
this.baseUrl = url;
@@ -103,7 +103,7 @@ class ClientBuilder {
103103
* @param protocol The protocol on the proxy server to which you wish to connect. If the proxy server uses HTTPS, then you must set the protocol to 'https'.
104104
* @param username The username to login to the proxy.
105105
* @param password The password to login to the proxy.
106-
* @return Returns <b>this</b> to accommodate method chaining.
106+
* @return ClientBuilder <b>this</b> to accommodate method chaining.
107107
*/
108108
withProxy(host, port, protocol, username, password) {
109109
this.proxy = {
@@ -125,52 +125,48 @@ class ClientBuilder {
125125
/**
126126
* Use this to add any additional headers you need.
127127
* @param customHeaders A String to Object <b>Map</b> of header name/value pairs.
128-
* @return Returns <b>this</b> to accommodate method chaining.
128+
* @return ClientBuilder <b>this</b> to accommodate method chaining.
129129
*/
130130
withCustomHeaders(customHeaders) {
131131
this.customHeaders = customHeaders;
132-
133132
return this;
134133
}
135134

136135
/**
137136
* Enables debug mode, which will print information about the HTTP request and response to console.log
138-
* @return Returns <b>this</b> to accommodate method chaining.
137+
* @return ClientBuilder <b>this</b> to accommodate method chaining.
139138
*/
140139
withDebug() {
141140
this.debug = true;
142-
143141
return this;
144142
}
145143

146144
/**
147145
* Allows the caller to specify the subscription license (aka "track") they wish to use.
148146
* @param licenses A String Array of licenses.
149-
* @returns Returns <b>this</b> to accommodate method chaining.
147+
* @returns ClientBuilder <b>this</b> to accommodate method chaining.
150148
*/
151149
withLicenses(licenses) {
152150
this.licenses = licenses;
153-
154151
return this;
155152
}
156153

157154
/**
158155
* Allows the caller to specify key and value pair that is added to the request
159156
* @param {string} key - The query parameter key
160157
* @param {string} value - The query parameter value
161-
* @return Returns <b>this</b> to accommodate method chaining.
158+
* @return ClientBuilder <b>this</b> to accommodate method chaining.
162159
*/
163160
withCustomQuery(key, value) {
164161
this.customQueries.set(key, value);
165-
166162
return this;
167163
}
168164

169165
/**
170166
* Allows the caller to specify key and value pair and appends the value associated with the key, seperated by a comma.
171167
* @param {string} key - The query parameter key
172168
* @param {string} value - The query parameter value
173-
* @return Returns <b>this</b> to accommodate method chaining.
169+
* @return ClientBuilder <b>this</b> to accommodate method chaining.
174170
*/
175171
withCustomCommaSeperatedQuery(key, value) {
176172
let values = this.customQueries.get(key);
@@ -185,7 +181,7 @@ class ClientBuilder {
185181

186182
/**
187183
* Adds to the request query to use the component analysis feature.
188-
* @return Returns <b>this</b> to accommodate method chaining.
184+
* @return ClientBuilder <b>this</b> to accommodate method chaining.
189185
*/
190186
withFeatureComponentAnalysis() {
191187
return this.withCustomCommaSeperatedQuery("features", "component-analysis");

0 commit comments

Comments
 (0)