Skip to content

Commit 2dc128f

Browse files
committed
fix: replace template literals
1 parent 333bedd commit 2dc128f

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "deepdetect-js",
3-
"version": "0.9.2",
3+
"version": "0.9.3",
44
"description": "DeepDetect JS client",
55
"license": "MIT",
66
"author": {

src/dd.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,10 @@ export class DD {
2727
if (opts.path != null) {
2828
// Browser support, uses opts.path
2929
// instead of opts.host and opts.port
30-
this.ddurl = `${window.location}${opts.path}`;
30+
this.ddurl = window.location + opts.path;
3131
} else {
3232
// NodeJS support, uses opts.host and opts.port
33-
this.ddurl = `${opts.https ? 'https' : 'http'}://${opts.host}:${
33+
this.ddurl = `${(opts.https ? 'https://' : 'http://') + opts.host}:${
3434
opts.port
3535
}`;
3636
}
@@ -210,8 +210,8 @@ export class DD {
210210
getTrain(sname, job = 1, timeout = 0, measureHist = false) {
211211
const params = {
212212
service: sname,
213-
job: `${job}`,
214-
timeout: `${timeout}`,
213+
job,
214+
timeout,
215215
};
216216

217217
if (measureHist) {
@@ -232,7 +232,7 @@ export class DD {
232232
deleteTrain(sname, job = 1) {
233233
const params = {
234234
service: sname,
235-
job: `${job}`,
235+
job,
236236
};
237237

238238
return this.delete(this.urls.train, null, params);

0 commit comments

Comments
 (0)