Cannot read properties of null (reading 'category_id')