Move check of region/realm/faction values into its own function