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.
When running a migrate task a JS error appears in the console warning about anonymous functions. The contents of hosting_migrate.js is not wrapped with:
(function($) {
// Stuff here
})(jQuery);
Patch coming.
Comment | File | Size | Author |
---|---|---|---|
#7 | jquery-error-2744961-7.patch | 1.21 KB | jeremyr |
Comments
Comment #2
jeremyr CreditAttribution: jeremyr as a volunteer commentedComment #3
ergonlogicThis appears to have broken the "Compare platforms" link.
Comment #4
ergonlogicNote that the "Compare platforms" link currently drops us out of the modal dialog, and thus is already broken. It ought to provide us the comparison table, within the modal, and allow the 'back' link to return us to the migration form.
Comment #5
jeremyr CreditAttribution: jeremyr as a volunteer commentedI see what I did... wrapped the whole damn thing when only the first part of should have been. Fixed in the attached patch.
This issue also uncovered a secondary problem with the Overlay. In testing the original problem I was not signed in as User 1 but rather a secondary account. User's who are not logged in as User 1 do not have permission to use the Overlay (modal dialog). This is why I didn't notice it was falling out of the modal. Also confirming that this bug was present prior to my patch. In testing a non-patched version as User 1 it still falls out.
Now that the topic is broached, and possibly deserves a distinct issue, can we make the use of the Overlay module optional? My personal preference is to disable the module when ever possible. Apparently one can get around the use of the Overlay by creating a secondary administrative user.
Comment #6
ergonlogicThe latest patch introduces some white-space issues, both incorrect indentation, and some trailing.
Hmm, that shouldn't be. I filed a bug report for that: #2745211: Modal dialogs only work for admin users
You can uncheck the "Use the overlay for administrative pages." option on your account settings to disable Overlays on a user-by-user basis.
As for removing it as a dependency, I'd be fine with making it completely optional, assuming we make whatever adjustments might be necessary. One interesting approach might be to move all the code that deals with the Overlay into a separate module that mostly consists of
hook_form_alter()s
to add it wherever needed. That module could then be enabled by default in the install profile, but not depended-upon by any other modules.Comment #7
jeremyr CreditAttribution: jeremyr as a volunteer commentedLet's try that patch one more time...
Comment #8
helmo CreditAttribution: helmo as a volunteer and at Initfour websolutions commentedComment #9
helmo CreditAttribution: helmo as a volunteer and at Initfour websolutions commentedI can't reproduce the 'warning about anonymous functions'
but do see
Comment #10
helmo CreditAttribution: helmo as a volunteer and at Initfour websolutions commentedWho can review this? Jon?
Comment #11
helmo CreditAttribution: helmo as a volunteer and at Initfour websolutions commentedPlease re-open if this can still be re-produced.