Skip to content

Commit

Permalink
group-call-002 - test if lefthook will use prettier to format my code
Browse files Browse the repository at this point in the history
  • Loading branch information
filipenevola committed Apr 13, 2024
1 parent 42910f3 commit 4e872fa
Showing 1 changed file with 30 additions and 30 deletions.
60 changes: 30 additions & 30 deletions group-call-002/TicketFilters.js
Original file line number Diff line number Diff line change
@@ -1,37 +1,37 @@
export const TicketFilters = {
BY_NAME: {
propName: 'eventName',
isRequired: false,
execute({query: {eventName}, event}) {
return !eventName || event.eventName.includes(eventName);
},
BY_NAME: {
propName: "eventName",
isRequired: false,
execute({ query: { eventName }, event }) {
return !eventName || event.eventName.includes(eventName);
},
BY_DATE: {
propName: 'eventDate',
isRequired: false,
execute({query: {eventDate}, event}) {
return !eventDate || event.eventDate === eventDate;
},
},
BY_DATE: {
propName: "eventDate",
isRequired: false,
execute({ query: { eventDate }, event }) {
return !eventDate || event.eventDate === eventDate;
},
BY_QUANTITY: {
propName: 'quantity',
isRequired: true,
execute({query: {quantity}, event}) {
return !quantity || event.quantity >= quantity;
},
},
BY_QUANTITY: {
propName: "quantity",
isRequired: true,
execute({ query: { quantity }, event }) {
return !quantity || event.quantity >= quantity;
},
BY_STATUS: {
propName: 'status',
isRequired: false,
execute({query: {status}, event}) {
return !status || event.eventStatus === status;
},
},
BY_STATUS: {
propName: "status",
isRequired: false,
execute({ query: { status }, event }) {
return !status || event.eventStatus === status;
},
BY_USER_VIP: {
propName: 'quantity',
isRequired: false,
execute({event, user}) {
return user?.isVIP || !event.onlyVIPUsers;
},
},
BY_USER_VIP: {
propName: "quantity",
isRequired: false,
execute({ event, user }) {
return user?.isVIP || !event.onlyVIPUsers;
},
},
};

0 comments on commit 4e872fa

Please sign in to comment.