signup.js needs an extra ";" to work with the JS aggregator in core.

Unfort I can't make a diff at the moment but the patch is trivial. Line 12, add a ";" after the } so it reads:

Drupal.signupShowSettingsAutoAttach = function () {
  $('div.signup-allow-radios input[@type=radio]').click(function () {
    $('div.signup-node-settings')[['hide', 'show', 'hide'][this.value]]();
  });
}<strong>;</strong>     
CommentFileSizeAuthor
#2 signup_js_aggregator.patch.txt684 bytesdww

Comments

dww’s picture

Status: Needs review » Needs work

I'm confused. There's no JS aggregator in D5, only in D6, and signup (obviously) hasn't been ported to D6 yet.

Eventually, once this is a concern, don't we also need a ; after the global killswitch function, too?

dww’s picture

StatusFileSize
new684 bytes

here's an actual patch (for both functions). everything still seems to work, but i don't know enough about this yet to just commit it.

m3avrck’s picture

You seem to have not seen: http://tedserbinski.com/2007/06/05/js-aggregation-drupal-5 ;-)

Anywho, the semi colon is only needed in the first function, not the latter. The reason for that is because it's in the form: var something = function() { }; -- when you do "var =" you *always* need the optional ";" which is sometimes confusing because it's a function, but really it's a var :-)

More details: http://tedserbinski.com/2007/03/29/javascript-compression

dww’s picture

Status: Needs work » Fixed

Ahh, ok. You folks and your sneaky backport patches. ;)

In that case, committed to HEAD and DRUPAL-5, but only with the ; on the variable assignment, not the killswitch function invocation.

Thanks,
-Derek

Anonymous’s picture

Status: Fixed » Closed (fixed)