Added a more descriptive error message when a missing "category" property is encountered.