From f985b6bef361e7ddde99396d539cee4d3a6ca5aa Mon Sep 17 00:00:00 2001 From: Frangu Vlad Date: Mon, 9 Apr 2018 10:54:40 +0300 Subject: [PATCH] fix(Role): allow edit method to null the color (#2447) --- src/structures/Role.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/structures/Role.js b/src/structures/Role.js index 777e1f5ae..a8e100ef6 100644 --- a/src/structures/Role.js +++ b/src/structures/Role.js @@ -179,7 +179,7 @@ class Role extends Base { return this.client.api.guilds[this.guild.id].roles[this.id].patch({ data: { name: data.name || this.name, - color: Util.resolveColor(data.color || this.color), + color: data.color !== null ? Util.resolveColor(data.color || this.color) : null, hoist: typeof data.hoist !== 'undefined' ? data.hoist : this.hoist, permissions: data.permissions, mentionable: typeof data.mentionable !== 'undefined' ? data.mentionable : this.mentionable,