Got rid of all the errors concerning Generic types inherited from NSObject...
Fixed bugs