git cl upload: Use default patchset message when user's message is "y"

Users sometimes type in "y" to confirm the default patchset message,
resulting in a patchset being uploaded with "y" as the message.

We can make a fair assumption that no-one would willingly use a patchset
message of "y", so this CL uses the default patchset message whenever
this happens.

(I have personally done this myself and have seen at least one other
person do the same.)

Bug: None
Change-Id: Iad314d35aa830b62152ab2910eb37d876b7e450b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2861643
Reviewed-by: Jochen Eisinger <jochen@chromium.org>
Commit-Queue: Michael Cui <mlcui@google.com>
diff --git a/git_cl.py b/git_cl.py
index fc77ef8..5ad4947 100755
--- a/git_cl.py
+++ b/git_cl.py
@@ -1456,6 +1456,10 @@
     if options.force or options.skip_title:
       return title
     user_title = gclient_utils.AskForData('Title for patchset [%s]: ' % title)
+
+    # Use the default title if the user confirms the default with a 'y'.
+    if user_title.lower() == 'y':
+      return title
     return user_title or title
 
   def CMDUpload(self, options, git_diff_args, orig_args):