respect EDITOR environment variable
minor cleanup to authentication