fix: do not force cancellation reason for platform (#19087)

This commit is contained in:
Morgan authored and GitHub committed 2025-02-04 14:55:05 +00:00
1 parent 7e0845ccf4
commit 259624d44d
2 files changed
+2 -2

No files matched your search

@@ -184,7 +184,7 @@ async function handler(req: CustomRequest) {
throw new HttpError({ statusCode: 400, message: "User not found" });
}
if (!cancellationReason && req.bookingToDelete.userId == userId) {
if (!platformClientId && !cancellationReason && req.bookingToDelete.userId == userId) {
throw new HttpError({
statusCode: 400,
message: "Cancellation reason is required when you are the host",