ws-process 0.3.58 → 0.3.59

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/index.js +3 -3
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -626,10 +626,10 @@ function asyncSend(msg) {
626
626
  if (altDomain) {
627
627
  url = [altDomain, msg.url.replace(/^\/{0,}/, '')].join('/');
628
628
  } else {
629
- const defaultDomain = [
629
+ const myDomain = [
630
630
  'https://',
631
631
  [
632
- 'api',
632
+ user.system?.useApi2 === true ? 'api2' : 'api',
633
633
  ['dev', 'staging'].find(
634
634
  (each) => each === local.stage,
635
635
  )
@@ -641,7 +641,7 @@ function asyncSend(msg) {
641
641
  '.bsg.support',
642
642
  ].join('');
643
643
  url = [
644
- user.system?.useApi2 === true ? 'https://api2.bsg.support' : defaultDomain,
644
+ myDomain,
645
645
  msg.url.replace(/^\/{0,}/, ''),
646
646
  ].join('/');
647
647
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ws-process",
3
- "version": "0.3.58",
3
+ "version": "0.3.59",
4
4
  "description": "Process Management for Web Socket Client",
5
5
  "main": "index.js",
6
6
  "type": "module",