Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add consume endpoint #719

Open
wants to merge 4 commits into
base: main
Choose a base branch
from
Open

Add consume endpoint #719

wants to merge 4 commits into from

Conversation

adammansson
Copy link
Collaborator

closes #718

@adammansson adammansson requested a review from Macludde February 10, 2025 20:18
@adammansson adammansson self-assigned this Feb 10, 2025
Copy link
Contributor

@Macludde Macludde left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fix linter, unused variable. Some small fixes but that can be fixed in future PR

Comment on lines +6 to +12
export const load: PageServerLoad = async ({ locals, params }) => {
const { user, prisma } = locals;
authorize(apiNames.WEBSHOP.CONSUME, user);

const consumeMessage = await consumeConsumable(prisma, params.id);
return consumeMessage;
};
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be put into actions instead of load, but can be done in future PR

@Macludde Macludde self-requested a review February 17, 2025 17:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: 🆕 New
Development

Successfully merging this pull request may close these issues.

consume endpoint
3 participants