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

lib

Package Overview
Dependencies
Maintainers
1
Versions
62
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

lib - npm Package Compare versions

Comparing version 1.0.3 to 1.0.4

4

cli/commands/init.js

@@ -48,7 +48,7 @@ 'use strict';

if (!force && cloc) {
if (!force && cloc !== process.cwd()) {
console.log();
console.log(chalk.bold.red('Oops!'));
console.log();
console.log(`A stdlib workspace already exists.`);
console.log(`A stdlib workspace already exists above this one.`);
console.log(`We recommend you do not initialize another.`);

@@ -55,0 +55,0 @@ console.log(`The path of the stdlib workspace is:`)

@@ -8,2 +8,3 @@ 'use strict';

const chalk = require('chalk');
const inquirer = require('inquirer');

@@ -54,2 +55,3 @@ let formatDigits = (num, figs) => {

set: '<key> <value> Sets a specified key-value pair',
'new-password': 'Sets a new password via a prompt',
'reset-password': '<email> Sends a password reset request for the specified e-mail address'

@@ -92,2 +94,52 @@ }

if (params.vflags['new-password']) {
return inquirer.prompt(
[
{
name: 'password',
type: 'password',
default: '',
message: 'New Password'
},
{
name: 'repeat_password',
type: 'password',
default: '',
message: 'Repeat Password'
}
],
(promptResult) => {
resource.request('v1/users').index({me: true}, (err, response) => {
if (err) {
return callback(err);
}
let user = response.data[0];
if (!user) {
return callback(new Error('We couldn\'t retrieve your user data. Try again shortly.'));
}
resource.request('v1/users').update(user.id, {}, promptResult, (err, response) => {
if (err) {
return callback(err);
}
let user = response.data[0];
if (!user) {
return callback(new Error('We couldn\'t change your password. Try again shortly.'));
}
return callback(null, 'Password changed successfully.');
});
});
}
);
}
let set = params.vflags.set || params.flags.s || [];

@@ -99,2 +151,5 @@ let update = null;

update[set[0]] = set.slice(1).join(' ');
if (update.password) {
return callback(new Error('Please use --new-password to set your password'));
}
}

@@ -101,0 +156,0 @@

{
"name": "lib",
"version": "1.0.3",
"version": "1.0.4",
"description": "Standard Library for Microservices",

@@ -5,0 +5,0 @@ "main": "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