This warning is still present in the latest version. On line 15, 1
should be changed to "edit_posts"
It need not necessarily be edit_posts
. It could be any suitable role or capability.
Fixed it in 1.3
Anyone with Editing post capability should be able to delete comments too. So setting that as capability level.
Thanks for the feedback Hareesh & KTS915
(@hareesh-pillai)
7 years, 11 months ago
Hi. Thanks for the great plugin. I’ve a concern. This
add_management_page()
function is passed a deprecated argument. So it throws a PHP notice.PHP Notice: has_cap was called with an argument that is deprecated since version 2.0! Usage of user levels by plugins and themes is deprecated. Use roles and capabilities instead. Instead of using the User level 1, using a suitable role or capability (
edit_posts
may be?) will solve this.https://wordpress.org/plugins/delete-all-comments/