Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
The SlickNav plugin causes a site's JavaScript to break when CSS/JS aggregation is enabled and using jQuery 1.10. The error message presented is as follows:
Uncaught SyntaxError: Unexpected identifier
After performing some investigation, it was found that SlickNav is missing commas at the end of statements, which throws jQuery "Unterminated statements" errors. When this JavaScript is then aggregated, it breaks.
I will attach a patch for review in a minute.
Comment | File | Size | Author |
---|---|---|---|
#4 | unterminated_statements-2677036-4.patch | 3.99 KB | kala4ek |
| |||
#2 | adminimal_admin_menu-unterminated_statements-2677036-2.patch | 3.78 KB | ron_s |
|
Comments
Comment #2
ron_s CreditAttribution: ron_s commentedHere is a patch for review. Once this has been finalized, I'd recommend asending this to the SlickNav developers so they can make sure to fix the issue in their code. Thanks.
Comment #4
kala4ekAttached new patch, which should pass tests.
Hate JS for such problems...
Comment #6
Tess BakkerFixed with commit http://cgit.drupalcode.org/adminimal_admin_menu/commit/?id=e40001cc62db9...
Comment #7
Tess Bakker