Revert "updates on the otp updates on the customer app"
This reverts commit 89321c9e06.
This commit is contained in:
@@ -8,7 +8,6 @@ import (
|
||||
"net/http"
|
||||
"os"
|
||||
"strconv"
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
"doormile/constants"
|
||||
@@ -264,15 +263,9 @@ func pickBestFromCandidates(candidates []*milerCandidate) *milerCandidate {
|
||||
// ─── AI layer HTTP call ──────────────────────────────────────────────────────
|
||||
|
||||
func callDecisionEngine(booking *models.PickupBooking, candidates []aiCandidate) (aiDecisionResponse, error) {
|
||||
// No hardcoded fallback. This used to default to the production AI layer,
|
||||
// so a developer running the backend locally sent real booking and rider
|
||||
// data to it without ever configuring anything. Unset now means "no AI
|
||||
// layer": the caller already falls back to legacy scoring when this
|
||||
// returns an error (see AI_LAYER_FALLBACK above), so degrading is the
|
||||
// designed path rather than a new one.
|
||||
baseURL := strings.TrimSpace(os.Getenv("AI_LAYER_BASE_URL"))
|
||||
baseURL := os.Getenv("AI_LAYER_BASE_URL")
|
||||
if baseURL == "" {
|
||||
return aiDecisionResponse{}, fmt.Errorf("AI_LAYER_BASE_URL is not set")
|
||||
baseURL = "https://routemate.workolik.com"
|
||||
}
|
||||
|
||||
now := time.Now()
|
||||
|
||||
Reference in New Issue
Block a user