added warning when switching roles