Add wp_stream_is_record_excluded filter #921
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is a feature request. I would like to hard-code the logic of whether a record is excluded from the log. The context is that the plug-in will be mu-installed on multiple multisites, but individual blog admins will not be able to view/configure the settings (or indeed, the logs themselves).
The plug-in is mu-installed rather than network activated because there are a number of different networks, each of which needs to be configured identically, and an mu-plugin with hard-coded settings is the most straightforward way of achieving this.
I could use
wp_stream_record_array
but that feels too low-level.The PR has made some minor changes to insert the filter, including renaming a local variable for clarity.