add .toObject() method to structures (#522)

* add .toObject() method to structures

* add compiled PMChannel change from last commit

* uncomment members in VoiceChannel toObject method
This commit is contained in:
Brian Tanner
2016-08-16 23:53:07 +07:00
committed by abal
parent e42178181d
commit fdfd41dd8c
21 changed files with 426 additions and 58 deletions

View File

@@ -18,6 +18,15 @@ export default class TextChannel extends ServerChannel{
return this.messages.get("id", this.lastMessageID);
}
toObject() {
let obj = super.toObject();
obj.topic = this.topic;
obj.lastMessageID = this.lastMessageID;
return obj;
}
setTopic(){
return this.client.setChannelTopic.apply(this.client, reg(this, arguments));
}