fix adaptor condition