Remove Meta Box on Post/Page

Is there a way to stop all but admins from using the Post Level Restriction Feature when creating a post - I dont want anyone but an admin to be able to restrict the content.

Hi Sean,

s2 checks for the user’s capability to edit posts or pages, but I understand you want someone to edit the post without setting s2 restrictions…

I guess you could use the hook ws_plugin__s2member_before_security_meta_box in src/includes/classes/ and set $post to false if the user is not admin…

Maybe something like this (untested):

add_action('ws_plugin__s2member_before_security_meta_box', function ($vars = array()) {
  if (!current_user_is('administrator'))
    $vars['__refs']['post'] = false;