server v1.0.10 (fixed updating restaurant)
updating restaurant was overwriting some data
This commit is contained in:
@@ -86,11 +86,16 @@ export async function createRestaurant(request, oldRestaurant) {
|
|||||||
imgUrl: img,
|
imgUrl: img,
|
||||||
workingHours: request.workingHours,
|
workingHours: request.workingHours,
|
||||||
lunchHours: request.lunchHours,
|
lunchHours: request.lunchHours,
|
||||||
|
lunchMenu: oldRestaurant.lunchMenu,
|
||||||
|
categories: oldRestaurant.categories,
|
||||||
description: sanitizer.sanitize.keepUnicode(request.description),
|
description: sanitizer.sanitize.keepUnicode(request.description),
|
||||||
tags: request.tags,
|
tags: request.tags,
|
||||||
links: request.links,
|
links: request.links,
|
||||||
phone: request.phone,
|
phone: request.phone,
|
||||||
hidden: request.hidden,
|
hidden: request.hidden,
|
||||||
|
subscriptionActive: oldRestaurant.subscriptionActive,
|
||||||
|
subscriptionDue: oldRestaurant.subscriptionDue,
|
||||||
|
subscriptionStarted: oldRestaurant.subscriptionStarted,
|
||||||
});
|
});
|
||||||
return restaurant;
|
return restaurant;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user