Move function hasFilter in Connection