fixed null pointer, added category table