diff --git a/src/Resources/public/Admin.js b/src/Resources/public/Admin.js index 1cc156186b..05ba210d4d 100644 --- a/src/Resources/public/Admin.js +++ b/src/Resources/public/Admin.js @@ -809,7 +809,7 @@ jQuery(document).on('sonata-admin-append-form-element', function(e) { Admin.setup_collection_counter(e.target); }); -jQuery(window).load(function() { +jQuery(window).on('load', function() { if (Admin.get_config('CONFIRM_EXIT')) { jQuery('.sonata-ba-form form').each(function() { jQuery(this).confirmExit();