move klass verification to method