[ Index ]

PHP Cross Reference of GlotPress

title

Body

[close]

/gp-includes/cli/ -> wipe-permissions.php (source)

   1  <?php
   2  
   3  class GP_CLI_Wipe_Permissions extends WP_CLI_Command {
   4  
   5  	public function __invoke() {
   6          WP_CLI::confirm( "This will erase all current permissions!\nAre you sure you want to delete them?" );
   7  
   8          if ( ! GP::$permission->delete_all() ) {
   9              WP_CLI::error( __( 'Error in deleting permissions.', 'glotpress' ) );
  10          }
  11  
  12          WP_CLI::success( __( 'Permissions were deleted. Now you can use `wp glotpress add-admin` to add a new administrator.', 'glotpress' ) );
  13      }
  14  }


Generated: Sun Dec 22 01:01:04 2024 Cross-referenced by PHPXref 0.7.1