From 48c3fbd67ae40e92edad8d19afdf2e0e2b5e2a80 Mon Sep 17 00:00:00 2001 From: Rima Shah Date: Wed, 5 Jul 2023 10:38:43 -0600 Subject: [PATCH] using the correct function to check if existing asn was modified. --- traffic_ops/traffic_ops_golang/asn/asns.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/traffic_ops/traffic_ops_golang/asn/asns.go b/traffic_ops/traffic_ops_golang/asn/asns.go index bd0ec3bf62..7b169363e9 100644 --- a/traffic_ops/traffic_ops_golang/asn/asns.go +++ b/traffic_ops/traffic_ops_golang/asn/asns.go @@ -331,9 +331,9 @@ func Update(w http.ResponseWriter, r *http.Request) { return } - requestedAsnId := inf.Params["id"] + requestedAsnId := inf.IntParams["id"] // check if the entity was already updated - userErr, sysErr, errCode = api.CheckIfUnModifiedByName(r.Header, inf.Tx, requestedAsnId, "asn") + userErr, sysErr, errCode = api.CheckIfUnModified(r.Header, inf.Tx, requestedAsnId, "asn") if userErr != nil || sysErr != nil { api.HandleErr(w, r, tx, errCode, userErr, sysErr) return