use locate-dominating-file instead of homegrown function