Updated nameing to fit the usual scheme

ref #6
This commit is contained in:
Nicolai Ort 2020-12-18 14:29:17 +01:00
parent efecffb72d
commit 476afc6a99
1 changed files with 5 additions and 5 deletions

View File

@ -67,7 +67,7 @@ export class CreateUser {
* Optional.
*/
@IsOptional()
groupId?: number[] | number
group?: number[] | number
//TODO: ProfilePics
@ -81,11 +81,11 @@ export class CreateUser {
throw new UsernameOrEmailNeededError();
}
if (this.groupId) {
if (!Array.isArray(this.groupId)) {
this.groupId = [this.groupId]
if (this.group) {
if (!Array.isArray(this.group)) {
this.group = [this.group]
}
const groupIDs: number[] = this.groupId
const groupIDs: number[] = this.group
let errors = 0
const validateusergroups = async () => {
let foundgroups = []