fixed: format query result (fields object) using layer metadata