Opened 8 years ago
Closed 8 years ago
#39148 closed enhancement (fixed)
Correct concatenated dynamic hooks
Reported by: | keesiemeijer | Owned by: | johnbillion |
---|---|---|---|
Milestone: | 4.7.1 | Priority: | normal |
Severity: | normal | Version: | |
Component: | General | Keywords: | has-patch |
Focuses: | docs | Cc: |
Description
Cleaning up concatenated dynamic hooks as per the coding-standards
Related: #38462
Attachments (1)
Change History (10)
#2
@
8 years ago
- Component changed from General to Formatting
- Keywords 2nd-opinion dev-feedback added
- Version set to trunk
Hi @keesiemeijer,
It's a good idea, but that means cleaning a lot of current hooks :confused:
Moreover, I've heard that when formatting and/or coding standards are in, rather than applying to all curent application it's preferable to only apply on new tickets.
#3
@
8 years ago
I understand, but the documentation in the code reference relies on the hook names to be correct. For a fun example look here: https://developer.wordpress.org/reference/hooks/handle_bulk_actions-get_current_screen-id/
Should I create separate tickets for all of them?
#6
@
8 years ago
- Keywords 2nd-opinion dev-feedback removed
- Milestone changed from Awaiting Review to 4.8
- Version trunk deleted
Thanks for the patch, @keesiemeijer.
These dynamic hook names are indeed incorrect. Here's an example of where the hook name gets messed up on the code reference:
https://developer.wordpress.org/reference/hooks/handle_bulk_actions-get_current_screen-id/
Use interpolation for naming of dynamic hooks