fix categories print for documents (with error)