type-arango
Version:
ArangoDB Foxx decorators and utilities for TypeScript
8 lines (6 loc) • 326 B
text/typescript
export class AttributeIsNotARelationError extends Error {
constructor(entity: string, attribute: string) {
super(`The attribute ${entity}.${attribute} is not a relation. Add either a @OneToOne or a @OneToMany decorator to the property of the entity.`)
Object.setPrototypeOf(this, new.target.prototype)
}
}