init stuff
This commit is contained in:
parent
abdd9579ff
commit
54448f3a4a
18 changed files with 3199 additions and 0 deletions
22
webpage/member.js
Normal file
22
webpage/member.js
Normal file
|
@ -0,0 +1,22 @@
|
|||
class member{
|
||||
constructor(memberjson){
|
||||
for(const thing of Object.keys(memberjson)){
|
||||
this[thing]=memberjson[thing];
|
||||
}
|
||||
this.user=new user(this.user);
|
||||
}
|
||||
hasRole(ID){
|
||||
for(const thing of this.roles){
|
||||
console.log(this.roles)
|
||||
if(thing.id===ID){
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
isAdmin(){
|
||||
console.log(this);
|
||||
return this.guild.properties.owner_id===this.user.id;
|
||||
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue