added logout(string username) to contract