Fixing class definitions