[pergola] write checking of object class even simpler (checking format)