Fix up a few bugs in the js code.

Review Request #8737 — Created Feb. 10, 2017 and submitted

Information

Review Board
release-3.0.x
0c47a94...

Reviewers

This change fixes a few issues that SonarQube surfaced:

  • In a couple places, we were iterating over object fields without testing
    hasOwnProperty.
  • The calls to testCloseDescription were passing too many arguments.
  • We were testing whether indexOf returned a value greater than zero, but
    zero is a valid return value.

Ran js-tests.

reviewbot
  1. Tool: PEP8 Style Checker
    Ignored Files:
        reviewboard/static/rb/js/models/tests/reviewRequestEditorModelTests.js
        reviewboard/static/rb/js/views/uploadAttachmentView.js
        reviewboard/static/rb/js/views/issueSummaryTableView.js
        reviewboard/static/rb/js/admin/repositoryform.js
    
    
    
    Tool: Pyflakes
    Ignored Files:
        reviewboard/static/rb/js/models/tests/reviewRequestEditorModelTests.js
        reviewboard/static/rb/js/views/uploadAttachmentView.js
        reviewboard/static/rb/js/views/issueSummaryTableView.js
        reviewboard/static/rb/js/admin/repositoryform.js
    
    
  2. 
      
brennie
  1. Ship It!
  2. 
      
chipx86
  1. Ship It!
  2. 
      
david
Review request changed

Status: Closed (submitted)

Change Summary:

Pushed to release-3.0.x (69baae8)
Loading...