Smoothed out the participant creation process regarting addresses
ref #13
This commit is contained in:
@@ -1,12 +1,12 @@
|
||||
import { IsString } from 'class-validator';
|
||||
import { NotAcceptableError, NotFoundError } from 'routing-controllers';
|
||||
|
||||
export class ParticipantOnlyOneAddressAllowedError extends NotAcceptableError {
|
||||
export class ParticipantAddressWrongTypeError extends NotAcceptableError {
|
||||
@IsString()
|
||||
name = "ParticipantOnlyOneAddressAllowedError"
|
||||
name = "ParticipantAddressWrongTypeError"
|
||||
|
||||
@IsString()
|
||||
message = "Participant's can only have one address! \n You provided an id and address object.."
|
||||
message = "The participant's address must be either a existing address, new address or a existing adress's id. \n You provided a object of another type."
|
||||
}
|
||||
|
||||
export class ParticipantAddressNotFoundError extends NotFoundError {
|
||||
|
||||
Reference in New Issue
Block a user