fix(export): Correct detection of admin mode (closes #5276)