Skip to content

Instantly share code, notes, and snippets.

@tareq1988
Created July 7, 2017 08:05
Show Gist options
  • Save tareq1988/3c432074eced2acf2217e5af1e9ce57d to your computer and use it in GitHub Desktop.
Save tareq1988/3c432074eced2acf2217e5af1e9ce57d to your computer and use it in GitHub Desktop.
Override pretty link admin area access role
<?php
/*
Plugin Name: Pretty Link Role Override
Description: Override pretty link admin area access role
Plugin URI: http://tareq.co
Author: Tareq Hasan
Author URI: http://tareq.co
Version: 1.0
License: GPL2
*/
add_action( 'init', function() {
global $plp_options;
if ( class_exists( 'PrliLink' ) && is_null( $plp_options ) ) {
$plp_options = new stdClass;
$plp_options->min_role = 'delete_others_pages';
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment