diff --git a/src/components/Avatar.tsx b/src/components/Avatar.tsx index 4dcffc9..adf99ac 100644 --- a/src/components/Avatar.tsx +++ b/src/components/Avatar.tsx @@ -35,7 +35,7 @@ interface IProps { const Avatar: React.FC = ({ className, avatarUrl, label }: IProps) => { const [src, setSrc] = useState(avatarUrl); useEffect(() => { - setSrc(avatarUrl); + setSrc(avatarUrl ? avatarUrl : logo); }, [avatarUrl]); const _className = classNames('avatar', className, {