ocket8888 commented on code in PR #7205:
URL: https://github.com/apache/trafficcontrol/pull/7205#discussion_r1026787434


##########
traffic_router/core/src/main/java/org/apache/traffic_control/traffic_router/core/dns/ZoneManager.java:
##########
@@ -453,6 +454,17 @@ private static List<Record> fillZones(final Map<String, 
List<Record>> zoneMap, f
                return records;
        }
 
+       protected static String getTRLocalHostname(final TrafficRouter tr) 
throws UnknownHostException {
+               // if there is only one TR in the CRConfig, just use that TR's 
hostname
+               // instead of checking for the local server's hostname
+               final boolean singleTR = 
Iterators.size(tr.getCacheRegister().getTrafficRouters().fieldNames()) == 1;

Review Comment:
   > would not be `null` or explicitly `undefined`
   
   `undefined` is not a value in JSON, that's just JS. You'll never see 
anything "explicitly `undefined`" because that's not syntactically valid.



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