Conditional redirect based on mount path. Fixes #231.