Fixed some problems in the classes