fixed class checking