@hazae41/mutex
Advanced tools
Comparing version 2.0.0 to 2.0.1
@@ -1,2 +0,1 @@ | ||
import { Result } from '@hazae41/result'; | ||
import { Awaitable } from '../../libs/promises/promises.js'; | ||
@@ -36,12 +35,6 @@ | ||
/** | ||
* Lock or return an error | ||
* @param callback | ||
* @returns | ||
*/ | ||
tryLock<R>(callback: (inner: T) => Awaitable<R>): Result<Promise<R>, LockedError>; | ||
/** | ||
* Lock or wait | ||
* @param callback | ||
*/ | ||
lock<R>(callback: (inner: T) => Awaitable<R>): Promise<R>; | ||
lockOrWait<R>(callback: (inner: T) => Awaitable<R>): Promise<R>; | ||
/** | ||
@@ -68,4 +61,3 @@ * Just wait | ||
lockOrThrow<R>(callback: (inner: T) => Awaitable<R>): Promise<R>; | ||
tryLock<R>(callback: (inner: T) => Awaitable<R>): Result<Promise<R>, LockedError>; | ||
lock<R>(callback: (inner: T) => Awaitable<R>): Promise<R>; | ||
lockOrWait<R>(callback: (inner: T) => Awaitable<R>): Promise<R>; | ||
wait(): Promise<void>; | ||
@@ -72,0 +64,0 @@ acquire(): Promise<Lock<T>>; |
{ | ||
"type": "module", | ||
"name": "@hazae41/mutex", | ||
"version": "2.0.0", | ||
"version": "2.0.1", | ||
"description": "Rust-like Mutex for TypeScript", | ||
@@ -25,4 +25,3 @@ "homepage": "https://github.com/hazae41/mutex", | ||
"dependencies": { | ||
"@hazae41/future": "^1.0.3", | ||
"@hazae41/result": "^1.1.8" | ||
"@hazae41/future": "^1.0.3" | ||
}, | ||
@@ -29,0 +28,0 @@ "devDependencies": { |
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
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
1
25427
341
- Removed@hazae41/result@^1.1.8
- Removed@hazae41/option@1.1.4(transitive)
- Removed@hazae41/result@1.3.2(transitive)