Socket
Socket
Sign inDemoInstall

@effect/data

Package Overview
Dependencies
Maintainers
3
Versions
79
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@effect/data - npm Package Compare versions

Comparing version 0.17.2 to 0.17.3

10

internal/Context.js

@@ -98,4 +98,8 @@ "use strict";

}
exports.ContextImpl = ContextImpl;
const serviceNotFoundError = tag => {
const impl = tag;
return new Error(`Service not found${impl.i0 ? `: ${impl.i0}` : ""}`);
};
/** @internal */
exports.ContextImpl = ContextImpl;
const isContext = u => typeof u === "object" && u !== null && "_id" in u && u["_id"] === ContextTypeId;

@@ -122,3 +126,3 @@ /** @internal */

if (!self.unsafeMap.has(tag)) {
throw new Error("Service not found");
throw serviceNotFoundError(tag);
}

@@ -131,3 +135,3 @@ return self.unsafeMap.get(tag);

if (!self.unsafeMap.has(tag)) {
throw new Error("Service not found");
throw serviceNotFoundError(tag);
}

@@ -134,0 +138,0 @@ return self.unsafeMap.get(tag);

@@ -27,3 +27,3 @@ "use strict";

toString() {
return `some(${String(this.i0)})`;
return `Some(${String(this.i0)})`;
}

@@ -77,3 +77,3 @@ toJSON() {

toString() {
return `none()`;
return `None()`;
}

@@ -80,0 +80,0 @@ toJSON() {

{
"name": "@effect/data",
"version": "0.17.2",
"version": "0.17.3",
"description": "Functional programming in TypeScript",

@@ -5,0 +5,0 @@ "license": "MIT",

@@ -95,2 +95,7 @@ import type * as C from "@effect/data/Context"

const serviceNotFoundError = (tag: C.Tag<any, any>) => {
const impl = tag as TagImpl<any, any>
return new Error(`Service not found${impl.i0 ? `: ${impl.i0}` : ""}`)
}
/** @internal */

@@ -137,3 +142,3 @@ export const isContext = (u: unknown): u is C.Context<never> =>

if (!self.unsafeMap.has(tag)) {
throw new Error("Service not found")
throw serviceNotFoundError(tag)
}

@@ -149,3 +154,3 @@ return self.unsafeMap.get(tag)! as any

if (!self.unsafeMap.has(tag)) {
throw new Error("Service not found")
throw serviceNotFoundError(tag)
}

@@ -152,0 +157,0 @@ return self.unsafeMap.get(tag)! as any

@@ -27,3 +27,3 @@ /**

toString() {
return `some(${String(this.i0)})`
return `Some(${String(this.i0)})`
}

@@ -69,3 +69,3 @@ toJSON() {

toString() {
return `none()`
return `None()`
}

@@ -72,0 +72,0 @@ toJSON() {

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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