Removing unused detect method