Skip to content

Commit

Permalink
Fix ordering of event-types (calcom#3126)
Browse files Browse the repository at this point in the history
  • Loading branch information
hariombalhara authored Jun 21, 2022
1 parent d7cd6e0 commit 2f5928b
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions apps/web/pages/[user]/[type].tsx
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,15 @@ async function getUserPageProps(context: GetStaticPropsContext) {
darkBrandColor: true,
eventTypes: {
select: { id: true },
// Order by position is important to ensure that the event-type that's enabled is the first in the list because for Free user only first is allowed.
orderBy: [
{
position: "desc",
},
{
id: "asc",
},
],
},
},
});
Expand Down

0 comments on commit 2f5928b

Please sign in to comment.