mitchell852 commented on code in PR #7307:
URL: https://github.com/apache/trafficcontrol/pull/7307#discussion_r1084427208


##########
traffic_portal/app/src/common/modules/form/deliveryService/FormDeliveryServiceController.js:
##########
@@ -215,7 +215,11 @@ var FormDeliveryServiceController = 
function(deliveryService, dsCurrent, origin,
                if (!dsCurrent) {
                        return "";
                }
-               return dsCurrent.active.split(" ").map(w => w[0].toUpperCase() 
+ w.substring(1).toLowerCase()).join(" ");
+               let {active} = dsCurrent;
+               if 
(!propertiesModel.properties.deliveryServices?.exposeInactive && active !== 
"ACTIVE") {
+                       active = "INACTIVE";
+               }
+               return active.split(" ").map(w => w[0].toUpperCase() + 
w.substring(1).toLowerCase()).join(" ");

Review Comment:
   why did i think the `=>` syntax would not work in TPv1? maybe i was thinking 
it was something else...



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