mirror of
https://github.com/danbulant/discord.js
synced 2026-05-27 14:02:02 +00:00
fix(Message): handle undefined/null content in cleanContent getter (#3778)
* Handle undefined/null content in Message#cleanContent * Typings * Update typings/index.d.ts Co-Authored-By: SpaceEEC <spaceeec@yahoo.com> Co-authored-by: SpaceEEC <spaceeec@yahoo.com>
This commit is contained in:
parent
878cc050d4
commit
a36f3869b3
1 changed files with 2 additions and 1 deletions
|
|
@ -301,7 +301,8 @@ class Message extends Base {
|
|||
* @readonly
|
||||
*/
|
||||
get cleanContent() {
|
||||
return Util.cleanContent(this.content, this);
|
||||
// eslint-disable-next-line eqeqeq
|
||||
return this.content != null ? Util.cleanContent(this.content, this) : null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Reference in a new issue