Fixed infinite event-type page loop after onboarding (#1782)

* added await to the promise

* removed logging remnants

* console log removed

Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
pull/1783/head^2
Syed Ali Shahbaz 2022-02-10 16:01:22 +05:30 committed by GitHub
parent aef6b70d8b
commit 55f1d727f8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -242,7 +242,7 @@ export default function Onboarding(props: inferSSRProps<typeof getServerSideProp
if (!props.eventTypes || props.eventTypes.length === 0) {
const eventTypes = await getEventTypes();
if (eventTypes.length === 0) {
Promise.all(
await Promise.all(
DEFAULT_EVENT_TYPES.map(async (event) => {
return await createEventType(event);
})