mirror of
https://github.com/rjNemo/rentease.git
synced 2026-06-12 13:46:51 +00:00
fix(api): return bookingURL only from sync endpoint
This commit is contained in:
parent
df1cd66cf1
commit
e138d493ab
1 changed files with 1 additions and 1 deletions
|
|
@ -50,7 +50,7 @@ func handleSync(bs *booking.Service) http.HandlerFunc {
|
||||||
|
|
||||||
w.Header().Set("Content-Type", "application/json")
|
w.Header().Set("Content-Type", "application/json")
|
||||||
w.WriteHeader(http.StatusCreated)
|
w.WriteHeader(http.StatusCreated)
|
||||||
if err := json.NewEncoder(w).Encode(fmt.Sprintf("👍 %s", bookingURL)); err != nil {
|
if err := json.NewEncoder(w).Encode(map[string]string{"bookingURL": bookingURL}); err != nil {
|
||||||
slog.Error("failed to write response", slog.Any("error", err))
|
slog.Error("failed to write response", slog.Any("error", err))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue