revised for category error