Bug Fix: JS var gDraftBanner not accessible globaly

Review Request #3182 — Created July 8, 2012 and submitted

Information

Review Board

Reviewers

Globalize gDraftBanner by attaching it to the global RB object.
Can't test this locally, needs a non-dev deployment.
chipx86
  1. I'm realizing I'm now confused about the repro case. The minified files are also combined such that everything that would ever need this file would have the reviews.min.js loaded. I think I'd need to look into this more. Definitely need to be 100% sure this is fixing it.
    1. Was this bug ever fixed? I ran into it again today on r.rb.org.
      
      It's not a matter of reviews.js not being loaded, it's the wrapper around reviews.js that isolates all internal definitions.
      
      You could place review_request_dlgs.html within the reviews.js wrapper, that should probably fix it but possibly break other things.
    2. You're right. I was forgetting that pipeline "helpfully" wrapped our JavaScript to hide globals.
      
      I've made one change to this, which is to assign to RB.draftBanner, instead of RB.gDraftBanner. The "g" prefix is meant for top-level globals, but isn't correct when assigned to something.
  2. 
      
ME
Review request changed
Status:
Completed
Change Summary:
Pushed to master (9c22446)