Update source/src/utils/service_env_validator.cpp
All checks were successful
Build-Test-Publish / build (linux/amd64) (push) Successful in 24s
Build-Test-Publish / build (linux/arm64) (push) Successful in 1m1s

This commit is contained in:
j
2026-01-02 21:48:02 +13:00
parent 065087053d
commit b20bf7476c

View File

@@ -75,7 +75,11 @@ bool validate_and_fix_service_env(
} }
// Find extra variables (in service but not in template or template_info) // Find extra variables (in service but not in template or template_info)
// Note: TEMPLATE is a special variable added when creating a service, never comment it out
for (const auto& service_var_name : service_var_names) { for (const auto& service_var_name : service_var_names) {
if (service_var_name == "TEMPLATE") {
continue; // Never treat TEMPLATE as an extra variable
}
if (template_var_names.find(service_var_name) == template_var_names.end() && if (template_var_names.find(service_var_name) == template_var_names.end() &&
template_info_var_names.find(service_var_name) == template_info_var_names.end()) { template_info_var_names.find(service_var_name) == template_info_var_names.end()) {
extra_vars.push_back(service_var_name); extra_vars.push_back(service_var_name);