UNPKG

idempotency-redis

Version:
22 lines (21 loc) 685 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.RedisCacheError = void 0; /** * Represents an error that occurred while interacting with the cache. */ class RedisCacheError extends Error { /** * Constructs an instance of RedisCacheError. * @param message The error message. * @param key The cache key associated with the error. * @param cause (Optional) The underlying error or reason for this error, if any. */ constructor(message, key, cause) { super(message); this.key = key; this.cause = cause; this.name = 'RedisCacheError'; } } exports.RedisCacheError = RedisCacheError;