games_app/backend/dist/games/errors.js
2026-06-29 15:01:23 +02:00

32 lines
1.2 KiB
JavaScript

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.UnsupportedGameActionError = exports.GameNotRegisteredError = exports.GameNotImplementedError = exports.GameNotFoundError = void 0;
class GameNotFoundError extends Error {
constructor(slug) {
super(`Game not found: ${slug}`);
this.name = 'GameNotFoundError';
}
}
exports.GameNotFoundError = GameNotFoundError;
class GameNotImplementedError extends Error {
constructor(slug) {
super(`Game has no implementation: ${slug}`);
this.name = 'GameNotImplementedError';
}
}
exports.GameNotImplementedError = GameNotImplementedError;
class GameNotRegisteredError extends Error {
constructor(implementationKey) {
super(`Game implementation not registered: ${implementationKey}`);
this.name = 'GameNotRegisteredError';
}
}
exports.GameNotRegisteredError = GameNotRegisteredError;
class UnsupportedGameActionError extends Error {
constructor(action) {
super(`Unsupported game action: ${action}`);
this.name = 'UnsupportedGameActionError';
}
}
exports.UnsupportedGameActionError = UnsupportedGameActionError;
//# sourceMappingURL=errors.js.map