Simplyfy code by adding a helper method
Added CheckPassword command
Added missing import