#53488 closed defect (bug) (fixed)
The `action` passed to jQuery.ajax is possibly `null`
Reported by: | ixkaito | Owned by: | desrosj |
---|---|---|---|
Milestone: | 5.8 | Priority: | normal |
Severity: | normal | Version: | |
Component: | Widgets | Keywords: | has-patch commit |
Focuses: | javascript | Cc: |
Description
When I add widgets from the Customizer, the console displays a TypeError action is null
. Need to check if action
and action.data
exist.
Attachments (2)
Change History (10)
#4
@
3 years ago
It seems like action
is explicitly set to null
here:
That code hasn't changed for last 5 years so it sounds like we're just triggering an unhappy path introduced in this commit:
https://github.com/WordPress/wordpress-develop/commit/39ecd7846d24f5dd46833b68c6cb90dcdc070398
Given that context, the fix looks good to me.
Note: See
TracTickets for help on using
tickets.
Why is
data
null? Perhaps@wordpress/customize-widgets
is doing something wrong cc. @kevin940726.