commonWP icon indicating copy to clipboard operation
commonWP copied to clipboard

make sure $hook_extra['plugins'] before using it.

Open matt-h opened this issue 5 years ago • 0 comments

We've had some errors that $hook_extra['plugins'] is not set when using it in this function.

It has only been with non WordPress.org plugins, but this should fix it to make sure that it is set before using it.

Also handle if $hook_extra['plugin'] is used to pass a single plugin. A case that I have an example of the $hook_extra variable contained the following data.

[
  'action' => 'update',
  'plugin' => 'wpmudev-updates/update-notifications.php',
  'type' => 'plugin'
]

matt-h avatar May 10 '19 16:05 matt-h