fix: handle undefined channelMetadata to prevent crash (#127094)
* 💥 fix(Channel): handle undefined channelMetadata to prevent crash
* Update Channel.js
* Update Channel.js
* Update Channel.js
Co-authored-by: @BenyFilho
* Update Channel.js
Co-authored-by: @BenyFilho
* Update Channel.js
Co-authored-by: @BenyFilho
* Update Channel.js
Co-authored-by: @BenyFilho
* Update Channel.js
Co-authored-by:
* fix: update description in Channel.js
co-authored-by: @BenyFilho
---------
Co-authored-by: BenyFilho <168232825+BenyFilho@users.noreply.github.com>
This commit is contained in:
parent
016a56bb56
commit
7f54af0986
1 changed files with 2 additions and 1 deletions
|
|
@ -41,7 +41,8 @@ class Channel extends Base {
|
||||||
* The channel description
|
* The channel description
|
||||||
* @type {string}
|
* @type {string}
|
||||||
*/
|
*/
|
||||||
this.description = data.channelMetadata.description;
|
this.description =
|
||||||
|
data.channelMetadata?.description ?? data.description ?? '';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Indicates if it is a Channel
|
* Indicates if it is a Channel
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue