Fixed the way parent classes are loaded