Fixed new classes not being created properly.