* Fix error during new site setup
* remove logging
<div>
<Theme
myUserInfo={siteRes.my_user}
- defaultTheme={siteRes.site_view.site.default_theme}
+ defaultTheme={siteRes?.site_view?.site?.default_theme}
/>
{siteRes &&
siteRes.site_view &&
interface Props {
myUserInfo: MyUserInfo | undefined;
- defaultTheme: string;
+ defaultTheme?: string;
}
export class Theme extends Component<Props> {
/>
</Helmet>
);
- } else if (this.props.defaultTheme != "browser") {
+ } else if (
+ this.props.defaultTheme != null &&
+ this.props.defaultTheme != "browser"
+ ) {
return (
<Helmet>
<link