Added functions to work with users in db