fix feature detection