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

@pheasantplucker/failables

Package Overview
Dependencies
Maintainers
5
Versions
17
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@pheasantplucker/failables - npm Package Compare versions

Comparing version 1.0.3 to 1.0.4

2

package.json
{
"name": "@pheasantplucker/failables",
"version": "1.0.3",
"version": "1.0.4",
"description": "to protect against null and throwing errors",

@@ -5,0 +5,0 @@ "main": "src/failable.js",

@@ -20,5 +20,5 @@ const equal = require("assert").deepEqual

const isSuccess = f => kind(f) === SUCCESS
const isFailure = f => kind(f) === FAILURE
const isEmpty = f => kind(f) === EMPTY
const isSuccess = f => Array.isArray(f) && kind(f) === SUCCESS
const isFailure = f => Array.isArray(f) && kind(f) === FAILURE
const isEmpty = f => Array.isArray(f) && kind(f) === EMPTY
const isFailable = f => {

@@ -25,0 +25,0 @@ if (protocolVersion(f) === PROTOCOL_V1) {

@@ -114,2 +114,5 @@ const equal = require('assert').deepEqual

equal(isFailable({foo: 'bar'}), false)
equal(isFailure(undefined), false)
equal(isSuccess('s'), false)
equal(isEmpty(7), false)
})

@@ -116,0 +119,0 @@ it('should fail a non-failable array', () => {

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