fix: 3 locations with return undefined (not compatible with React 17)

This commit is contained in:
Tom Moor
2021-06-13 17:47:17 -07:00
parent 470920e2c3
commit 2ca57fc7cf
3 changed files with 5 additions and 3 deletions

View File

@ -9,7 +9,9 @@ type Props = {
export default class Analytics extends React.Component<Props> { export default class Analytics extends React.Component<Props> {
componentDidMount() { componentDidMount() {
if (!env.GOOGLE_ANALYTICS_ID) return; if (!env.GOOGLE_ANALYTICS_ID) {
return null;
}
// standard Google Analytics script // standard Google Analytics script
window.ga = window.ga =

View File

@ -25,7 +25,7 @@ function NewDocumentMenu() {
const can = policies.abilities(team.id); const can = policies.abilities(team.id);
if (!can.createDocument) { if (!can.createDocument) {
return; return null;
} }
if (singleCollection) { if (singleCollection) {

View File

@ -23,7 +23,7 @@ function NewTemplateMenu() {
const can = policies.abilities(team.id); const can = policies.abilities(team.id);
if (!can.createDocument) { if (!can.createDocument) {
return; return null;
} }
return ( return (