mirror of
https://github.com/aaronpo97/the-biergarten-app.git
synced 2026-02-16 20:13:49 +00:00
Refactor: update beer post services, comment services
This commit is contained in:
@@ -20,12 +20,11 @@ const sendEditBeerPostRequest = async ({
|
||||
ibu,
|
||||
id,
|
||||
name,
|
||||
styleId,
|
||||
}: z.infer<typeof EditBeerPostValidationSchema>) => {
|
||||
const response = await fetch(`/api/beers/${id}`, {
|
||||
method: 'PUT',
|
||||
headers: { 'Content-Type': 'application/json' },
|
||||
body: JSON.stringify({ abv, description, ibu, name, styleId, id }),
|
||||
body: JSON.stringify({ abv, description, ibu, name, id }),
|
||||
});
|
||||
|
||||
if (!response.ok) {
|
||||
|
||||
Reference in New Issue
Block a user