From 680c6724b62794889b1faf1df18f053adef2562b Mon Sep 17 00:00:00 2001 From: Tudor Stanciu Date: Sat, 6 Jun 2020 14:21:54 +0300 Subject: [PATCH] wizard avatar fix --- src/features/chatbot/components/Wizard.js | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/features/chatbot/components/Wizard.js b/src/features/chatbot/components/Wizard.js index 7ec2d0b..aa80c25 100644 --- a/src/features/chatbot/components/Wizard.js +++ b/src/features/chatbot/components/Wizard.js @@ -73,12 +73,21 @@ const Wizard = ({ dismissBot }) => { setTimeout(dismissBot, 3000); }; + const getAvatar = () => { + const basePath = "public/icons/wizard.png"; + if (process.env.PUBLIC_URL) { + return `${process.env.PUBLIC_URL}/${basePath}`; + } else { + return basePath; + } + }; + return (