Issue #1264674 by bvanmeurs: Account settings are now properly checked, new function isolates this check from rest of code.