Skip to content

Commit 993766c

Browse files
author
James Lees
committed
Use real URL instead of hardcoded localhost
1 parent 8dfed8c commit 993766c

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/safari-client.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ import BaseClient from './base-client';
33
import { version as sdkVersion } from '../package.json';
44
import { RegistrationState } from './base-client';
55

6-
const __url = 'https://localhost:8080';
76
const platform = 'safari';
87

98
export class SafariClient extends BaseClient {
@@ -21,7 +20,9 @@ export class SafariClient extends BaseClient {
2120
async _init() {
2221
let { websitePushId } = await this._fetchWebsitePushId();
2322
this._websitePushId = websitePushId;
24-
this._serviceUrl = __url;
23+
this._serviceUrl = `${
24+
this._baseURL
25+
}/safari_api/v1/instances/${encodeURIComponent(this.instanceId)}`;
2526

2627
if (this._deviceId !== null) {
2728
return;

0 commit comments

Comments
 (0)