Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

pm2wick

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

pm2wick - npm Package Compare versions

Comparing version 1.1.3 to 1.1.4

16

dist/lib/generateId.js

@@ -35,7 +35,13 @@ "use strict";

try {
const hostname = os.hostname();
const uniqueId = `${hostname}-${(0, uuid_1.v4)()}`;
customFs.writeFileSync(ID_FILE, uniqueId, 'utf-8');
console.log(`Generated and saved new User ID: ${uniqueId}`);
return uniqueId;
if (customFs.existsSync(ID_FILE)) {
console.log(`User ID file found at: ${ID_FILE}`);
return customFs.readFileSync(ID_FILE, 'utf-8').trim();
}
else {
const hostname = os.hostname();
const uniqueId = `${hostname}-${(0, uuid_1.v4)()}`;
customFs.writeFileSync(ID_FILE, uniqueId, 'utf-8');
console.log(`Generated and saved new User ID: ${uniqueId}`);
return uniqueId;
}
}

@@ -42,0 +48,0 @@ catch (error) {

@@ -11,8 +11,13 @@ import * as fs from 'fs';

try {
const hostname = os.hostname();
const uniqueId = `${hostname}-${uuidv4()}`;
customFs.writeFileSync(ID_FILE, uniqueId, 'utf-8');
console.log(`Generated and saved new User ID: ${uniqueId}`);
return uniqueId;
if (customFs.existsSync(ID_FILE)) {
console.log(`User ID file found at: ${ID_FILE}`);
return customFs.readFileSync(ID_FILE, 'utf-8').trim();
} else {
const hostname = os.hostname();
const uniqueId = `${hostname}-${uuidv4()}`;
customFs.writeFileSync(ID_FILE, uniqueId, 'utf-8');
console.log(`Generated and saved new User ID: ${uniqueId}`);
return uniqueId;
}
} catch (error) {

@@ -19,0 +24,0 @@ console.error('Failed to generate or read unique ID:', error);

{
"name": "pm2wick",
"version": "1.1.3",
"version": "1.1.4",
"description": "Manage your PM2 processes.",

@@ -5,0 +5,0 @@ "main": "dist/index.js",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc