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

@form8ion/core

Package Overview
Dependencies
Maintainers
2
Versions
46
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@form8ion/core - npm Package Compare versions

Comparing version 1.2.3-alpha.1 to 1.3.0-alpha.1

32

lib/index.cjs.js

@@ -43,15 +43,27 @@ 'use strict';

function unlicensedConfirmationShouldBePresented(answers) {
return 'Private' === answers[questionNames.VISIBILITY];
function unlicensedConfirmationShouldBePresented(decisions) {
return answers => {
const values = {...decisions, ...answers};
return 'Private' === values[questionNames.VISIBILITY];
};
}
function licenseChoicesShouldBePresented(answers) {
return 'Public' === answers[questionNames.VISIBILITY] || !answers[questionNames.UNLICENSED];
function licenseChoicesShouldBePresented(decisions) {
return answers => {
const values = {...decisions, ...answers};
return 'Public' === values[questionNames.VISIBILITY] || !values[questionNames.UNLICENSED];
};
}
function copyrightInformationShouldBeRequested(answers) {
return !!answers[questionNames.LICENSE];
function copyrightInformationShouldBeRequested(decisions) {
return answers => {
const values = {...decisions, ...answers};
return !!values[questionNames.LICENSE];
};
}
function includeLicenseQuestions(copyrightHolder) {
function includeLicenseQuestions(decisions, copyrightHolder) {
return [

@@ -62,3 +74,3 @@ {

type: 'confirm',
when: unlicensedConfirmationShouldBePresented,
when: unlicensedConfirmationShouldBePresented(decisions),
default: true

@@ -70,3 +82,3 @@ },

type: 'list',
when: licenseChoicesShouldBePresented,
when: licenseChoicesShouldBePresented(decisions),
choices: Array.from(spdxLicenseList__default['default']),

@@ -105,3 +117,3 @@ default: 'MIT'

},
...includeLicenseQuestions(copyrightHolder)
...includeLicenseQuestions(decisions, copyrightHolder)
];

@@ -108,0 +120,0 @@ }

@@ -35,15 +35,27 @@ import { promises } from 'fs';

function unlicensedConfirmationShouldBePresented(answers) {
return 'Private' === answers[questionNames.VISIBILITY];
function unlicensedConfirmationShouldBePresented(decisions) {
return answers => {
const values = {...decisions, ...answers};
return 'Private' === values[questionNames.VISIBILITY];
};
}
function licenseChoicesShouldBePresented(answers) {
return 'Public' === answers[questionNames.VISIBILITY] || !answers[questionNames.UNLICENSED];
function licenseChoicesShouldBePresented(decisions) {
return answers => {
const values = {...decisions, ...answers};
return 'Public' === values[questionNames.VISIBILITY] || !values[questionNames.UNLICENSED];
};
}
function copyrightInformationShouldBeRequested(answers) {
return !!answers[questionNames.LICENSE];
function copyrightInformationShouldBeRequested(decisions) {
return answers => {
const values = {...decisions, ...answers};
return !!values[questionNames.LICENSE];
};
}
function includeLicenseQuestions(copyrightHolder) {
function includeLicenseQuestions(decisions, copyrightHolder) {
return [

@@ -54,3 +66,3 @@ {

type: 'confirm',
when: unlicensedConfirmationShouldBePresented,
when: unlicensedConfirmationShouldBePresented(decisions),
default: true

@@ -62,3 +74,3 @@ },

type: 'list',
when: licenseChoicesShouldBePresented,
when: licenseChoicesShouldBePresented(decisions),
choices: Array.from(spdxLicenseList),

@@ -97,3 +109,3 @@ default: 'MIT'

},
...includeLicenseQuestions(copyrightHolder)
...includeLicenseQuestions(decisions, copyrightHolder)
];

@@ -100,0 +112,0 @@ }

@@ -5,3 +5,3 @@ {

"license": "MIT",
"version": "1.2.3-alpha.1",
"version": "1.3.0-alpha.1",
"files": [

@@ -65,3 +65,3 @@ "example.js",

"lockfile-lint": "4.3.7",
"mocha": "8.2.0",
"mocha": "8.2.1",
"mock-fs": "4.13.0",

@@ -68,0 +68,0 @@ "npm-run-all": "4.1.5",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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