uranusjr commented on code in PR #72940:
URL: https://github.com/apache/airflow/pull/72940#discussion_r4439837810


##########
registry/src/provider-version.njk:
##########
@@ -37,6 +37,13 @@ eleventyComputed:
   {% set sourceUrl = pv.provider.source_url %}
 {% endif %}
 
+{% set externalServiceRows = [] %}
+{% for conn in conns %}
+  {% if conn.external_services and conn.external_services.length > 0 %}
+    {% set externalServiceRows = (externalServiceRows.push({name: 
conn.conn_type or conn.connection_type, services: conn.external_services}), 
externalServiceRows) %}

Review Comment:
   This only works because Nunjucks compiles a parenthesized group into a JS 
comma expression. It's hard to read, and it remaps conn into a new {name, 
services} shape for no gain. It’s probably better to make this a filter instead.



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