Skip to content

Commit

Permalink
using the correct function to check if existing asn was modified.
Browse files Browse the repository at this point in the history
  • Loading branch information
rimashah25 committed Jul 5, 2023
1 parent d8352bb commit 48c3fbd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions traffic_ops/traffic_ops_golang/asn/asns.go
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down

0 comments on commit 48c3fbd

Please sign in to comment.