fix bug in categories