better handling for multi-domain authorization