• 
      

    Bullet-proof pre-commit UI a bit.

    Review Request #6365 — Created Sept. 23, 2014 and submitted

    Information

    Review Board
    release-2.0.x
    21c1914...

    Reviewers

    When receiving an unexpected error from the server, the frontend code for the
    pre-commit upload would hit a TypeError, preventing it from completing the
    process and leaving the browser with a forever "Loading..." message. This
    change updates it to check when the response can't be parsed as JSON and show
    "Unknown error" instead.

    While I was in here I fixed up some of the nearby localization to be more
    correct.

    • Checked that uploading a diff through the pre-commit UI still worked as
      expected.
    • Ran js-tests.
    reviewbot
    1. Tool: PEP8 Style Checker
      Ignored Files:
          reviewboard/static/rb/js/newReviewRequest/models/preCommitModel.js
      
      
      
      Tool: Pyflakes
      Ignored Files:
          reviewboard/static/rb/js/newReviewRequest/models/preCommitModel.js
      
      
    2. 
        
    chipx86
    1. Ship It!

    2. 
        
    david
    Review request changed
    Status:
    Completed
    Change Summary:
    Pushed to release-2.0.x (e2794cc)