simpler, more robust resolve fn
0.10.3