Summary
template_import() logs import errors using $message inside the errors loop, but loop variable is $error.
Current code (simplified):
foreach ($return_data['errors'] as $error) {
cacti_log('... ' . $message, ...);
}
Impact
- Error logs can show stale/incorrect messages from another loop.
- Troubleshooting import failures becomes misleading.
Location
thold_templates.php, template_import() function.
Expected
Log $error within the error loop so log output matches the actual error entry.