fix(ClientApplication): owner is still nullable

Fixes #3358
This commit is contained in:
SpaceEEC
2019-06-26 20:12:05 +02:00
parent 4c11347511
commit 1dd4c041e0
2 changed files with 7 additions and 3 deletions

View File

@@ -68,9 +68,13 @@ class ClientApplication extends Base {
/**
* The owner of this OAuth application
* @type {User|Team}
* @type {?User|Team}
*/
this.owner = data.team ? new Team(this.client, data.team) : this.client.users.add(data.owner);
this.owner = data.team ?
new Team(this.client, data.team) ?
data.owner :
this.client.users.add(data.owner) :
null;
}
/**