rimashah25 commented on code in PR #6593:
URL: https://github.com/apache/trafficcontrol/pull/6593#discussion_r856321941


##########
traffic_ops/traffic_ops_golang/dbhelpers/db_helpers.go:
##########
@@ -2091,6 +2091,43 @@ func UpdateServerProfileTableForV2V3(id *int, newProfile 
*string, origProfile st
        return profileName, nil
 }
 
+// GetServerDetailFromV4 function converts server details from V4 to V3/V2
+func GetServerDetailFromV4(sd tc.ServerDetailV40, tx *sql.Tx) 
(tc.ServerDetail, error) {
+       var profileDesc *string
+       if err := tx.QueryRow(`SELECT p.description FROM profile p WHERE 
p.name=$1`, sd.ProfileNames[0]).Scan(&profileDesc); err != nil {
+               return tc.ServerDetail{}, fmt.Errorf("querying profile 
description by profile name: " + err.Error())

Review Comment:
   ugh, missed it.



-- 
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]

Reply via email to