resolver. Convert it to the less hacky one used elsewhere, mainly so that I won't miss it when implementing a more general solution to this common problem.