From 9cf71dcf664a8e67526302ea763ccded55779c95 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Joel=20Elias=20M=C3=A9ndez?= <67445275+joelmendez1@users.noreply.github.com> Date: Tue, 8 Feb 2022 14:01:43 -0300 Subject: [PATCH] [DEV-224] Error in edit topic icon color (#1143) --- client/src/app-components/topic-viewer.js | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/client/src/app-components/topic-viewer.js b/client/src/app-components/topic-viewer.js index 8bdc9276..be894500 100644 --- a/client/src/app-components/topic-viewer.js +++ b/client/src/app-components/topic-viewer.js @@ -124,13 +124,15 @@ class TopicViewer extends React.Component { } renderEditModal() { - let props = { - topicId: this.props.id, - onChange: this.props.onChange, + const {id, onChange, name, icon, iconColor} = this.props; + + const props = { + topicId: id, + onChange, defaultValues: { - title: this.props.name, - icon: this.props.icon, - iconColor: this.props.iconColor, + title: name, + icon, + color: iconColor, private: this.props.private * 1 } };