Stop using HAVE_MODULE_{DIRAUTH,RELAY} inside functions
In doc/HACKING/Modules.md, we say that we don't use module macros inside functions. But HAVE_MODULE_DIRAUTH and HAVE_MODULE_RELAY are used inside a few functions.
We should stop using HAVE_MODULE_DIRAUTH and HAVE_MODULE_RELAY inside functions, or update the documentation to say "avoid using".