[feat] loading inventory
This commit is contained in:
@@ -145,16 +145,11 @@ export const POST: APIRoute = async ({ request, locals }) => {
|
||||
break;
|
||||
|
||||
default:
|
||||
return new Response(
|
||||
'Invalid action',
|
||||
{
|
||||
status: 400,
|
||||
headers: { 'Content-Type': 'text/html' }
|
||||
}
|
||||
);
|
||||
// No action = list inventory for this card
|
||||
return getInventory(userId!, cardId);
|
||||
}
|
||||
|
||||
// Always return current inventory
|
||||
// Always return current inventory after a mutation
|
||||
return getInventory(userId!, cardId);
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user