Remove old autodetect code