Re: proper way to do autodetection