Added extra entity type check for admin settings form. Last operational version before object refactoring.
Removed Pair class.