rimashah25 commented on code in PR #7734:
URL: https://github.com/apache/trafficcontrol/pull/7734#discussion_r1303703236
##########
traffic_ops/traffic_ops_golang/profile/profiles.go:
##########
@@ -226,10 +228,10 @@ LEFT JOIN cdn c ON prof.cdn = c.id`
return query
}
-func ReadParameters(tx *sqlx.Tx, parameters map[string]string, user
*auth.CurrentUser, profile tc.ProfileNullable) ([]tc.ParameterNullable, error) {
+func ReadParameters(tx *sqlx.Tx, user *auth.CurrentUser, profileID *int)
([]tc.ParameterNullable, error) {
privLevel := user.PrivLevel
queryValues := make(map[string]interface{})
- queryValues["profile_id"] = *profile.ID
+ queryValues["profile_id"] = profileID
Review Comment:
And why would it be nil? Both times before calling this function, I am
checking for profileID
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]