Ruby on Rails | Screencasts | Download | Documentation | Weblog | Community | Source

Ticket #7301 (closed defect: duplicate)

Opened 1 year ago

Last modified 3 weeks ago

Missing semicolon prevents "minifying" of prototype.js

Reported by: mschuerig Assigned to: sam
Priority: normal Milestone: 1.x
Component: Prototype Version: edge
Severity: minor Keywords: jsmin asset packager
Cc: mislav

Description

A missing semicolon is preventing "minifying" of prototype.js using jsmin and consequently the asset packager plugin.

Index: actionpack/lib/action_view/helpers/javascripts/prototype.js
===================================================================
--- actionpack/lib/action_view/helpers/javascripts/prototype.js (revision 6010)
+++ actionpack/lib/action_view/helpers/javascripts/prototype.js (working copy)
@@ -843,7 +843,7 @@
     }

     params = Hash.toQueryString(params);
-    if (params && /Konqueror|Safari|KHTML/.test(navigator.userAgent)) params += '&_='
+    if (params && /Konqueror|Safari|KHTML/.test(navigator.userAgent)) params += '&_=';

     // when GET, append parameters to URL
     if (this.method == 'get' && params)

Change History

02/06/07 16:27:39 changed by mislav

  • status changed from new to closed.
  • resolution set to wontfix.

see #4191, #4729, #7311

we will add this semicolon somewhere in the future for consistency with the rest of the code, but we will not write code towards "compatibility" with various packers

02/24/07 21:50:13 changed by mislav

  • cc set to mislav.

04/22/08 19:00:01 changed by jdalton

  • status changed from closed to reopened.
  • resolution deleted.

04/22/08 19:01:08 changed by jdalton

  • status changed from reopened to closed.
  • resolution set to duplicate.

dup of #9218 (fixed ticket)

04/22/08 19:03:29 changed by jdalton

erm dup of #9140, #9218 was for scripty which was also recently added (in git repo)