Refactoring of coreUsers.php, removed old mysql dependency