Plugin Directory

Changeset 3224937


Ignore:
Timestamp:
01/18/2025 08:58:25 PM (8 weeks ago)
Author:
francescotaurino
Message:

Version 2.8, Tested up to Wp 6.7

Location:
reset-roles-and-capabilities
Files:
6 edited
1 copied

Legend:

Unmodified
Added
Removed
  • reset-roles-and-capabilities/tags/2.8/CHANGELOG.md

    r3047211 r3224937  
    33The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
    44and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
     5
     6## [2.8] - 2025-01-18
     7
     8### Changed
     9- Tested up to WP 6.7
    510
    611## [2.7] - 2024-03-07
     
    2025
    2126## [2.4] - 2022-08-17
    22 
    23 ### Fixed
    24 - Removed "Trunk" folder from Tagged Version
    2527
    2628### Changed
  • reset-roles-and-capabilities/tags/2.8/readme.txt

    r3047211 r3224937  
    33Tags: reset, roles, capabilities, default, users
    44Requires at least: 2.9
    5 Tested up to: 6.4
    6 Stable tag: 2.7
     5Tested up to: 6.7
     6Stable tag: 2.8
    77License: GPLv2 or later
    88License URI: http://www.gnu.org/licenses/gpl-2.0.html
    99
    1010
     11Resets WordPress Roles and Capabilities to their defaults and deactivates the plugin after the process is completed.
     12
     13== Description ==
     14
    1115This plugin does only one thing: Reset Roles and Capabilities to WordPress defaults. Just install and activate it.
    1216Once the process is finished, the plugin will deactivate itself.
    13 
    1417
    1518== Changelog ==
  • reset-roles-and-capabilities/tags/2.8/reset-roles-and-capabilities.php

    r3047211 r3224937  
    44 * Plugin URI:        https://wordpress.org/plugins/reset-roles-and-capabilities/
    55 * Description:       Reset Roles and Capabilities to WordPress defaults
    6  * Version:           2.7
     6 * Version:           2.8
    77 * Requires at least: 2.9
    88 * Author:            Francesco Taurino
     
    1515 */
    1616namespace ResetRolesAndCapabilities;
     17
    1718/**
    1819 * Transient Name & Plugin Slug
     
    2122
    2223/**
    23  * Time until expiration in seconds
     24 * Expiration time in seconds.
    2425 */
    2526const TRANSIENT_TIME = 600;
    2627
    2728/*
    28  * Set the activation hook
     29 * Set the activation hook.
    2930 */
    3031register_activation_hook( __FILE__, function ()
     
    4445
    4546        /**
    46          * Fetch a Role definition.
     47         * Fetches a role definition.
    4748         */
    4849        $role = get_role($role_name);
     
    5152
    5253            /**
    53              * Removes a capability from a role
     54             * Removes a capability from a role.
    5455             */
    5556            $role->remove_cap($capability);
     
    5859
    5960        /**
    60          * Remove role, if it exists.
     61         * Removes the role, if it exists.
    6162         */
    6263        remove_role($role_name);
     
    6566
    6667    /**
    67      * Execute WordPress role creation for the various WordPress versions.
     68     * Executes WordPress role creation for various WordPress versions.
    6869     */
    6970    populate_roles();
    7071
    7172    /**
    72      * Set a transient to show a success message
    73      */ 
    74     set_transient(TRANSIENT_NAME, __('Roles and Capabilities have been reset to WordPress defaults. The plugin has been deactivated.', 'reset-roles-and-capabilities'), TRANSIENT_TIME);
     73     * Sets a transient to show a success message.
     74     */
     75    set_transient(TRANSIENT_NAME, __('The roles and capabilities have been reset to WordPress defaults, and the plugin has been deactivated.', 'reset-roles-and-capabilities'), TRANSIENT_TIME);
    7576
    7677});
     
    7879 
    7980/**
    80  * Back compatibility
    81  * WordPress < 4.6
     81 * Backward compatibility for WordPress < 4.6.
    8282 * @link https://developer.wordpress.org/plugins/internationalization/how-to-internationalize-your-plugin/#loading-text-domain
    8383 */
     
    8989
    9090/**
    91  * Hide default admin notice on plugin activation
     91 * Hides the default admin notice on plugin activation.
    9292 */
    9393add_action( 'admin_head', function()
     
    9797
    9898/**
    99  * Show a message after activation and then delete the transient
     99 * Shows a message after activation and then deletes the transient.
    100100 */
    101101add_action('admin_notices', function ()
     
    116116
    117117/**
    118  * Deactivate the plugin
     118 * Deactivates the plugin.
    119119 */
    120120add_action('admin_init', function ()
  • reset-roles-and-capabilities/trunk/CHANGELOG.md

    r3047211 r3224937  
    33The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
    44and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
     5
     6## [2.8] - 2025-01-18
     7
     8### Changed
     9- Tested up to WP 6.7
    510
    611## [2.7] - 2024-03-07
     
    2025
    2126## [2.4] - 2022-08-17
    22 
    23 ### Fixed
    24 - Removed "Trunk" folder from Tagged Version
    2527
    2628### Changed
  • reset-roles-and-capabilities/trunk/readme.txt

    r3047211 r3224937  
    33Tags: reset, roles, capabilities, default, users
    44Requires at least: 2.9
    5 Tested up to: 6.4
    6 Stable tag: 2.7
     5Tested up to: 6.7
     6Stable tag: 2.8
    77License: GPLv2 or later
    88License URI: http://www.gnu.org/licenses/gpl-2.0.html
    99
    1010
     11Resets WordPress Roles and Capabilities to their defaults and deactivates the plugin after the process is completed.
     12
     13== Description ==
     14
    1115This plugin does only one thing: Reset Roles and Capabilities to WordPress defaults. Just install and activate it.
    1216Once the process is finished, the plugin will deactivate itself.
    13 
    1417
    1518== Changelog ==
  • reset-roles-and-capabilities/trunk/reset-roles-and-capabilities.php

    r3047211 r3224937  
    44 * Plugin URI:        https://wordpress.org/plugins/reset-roles-and-capabilities/
    55 * Description:       Reset Roles and Capabilities to WordPress defaults
    6  * Version:           2.7
     6 * Version:           2.8
    77 * Requires at least: 2.9
    88 * Author:            Francesco Taurino
     
    1515 */
    1616namespace ResetRolesAndCapabilities;
     17
    1718/**
    1819 * Transient Name & Plugin Slug
     
    2122
    2223/**
    23  * Time until expiration in seconds
     24 * Expiration time in seconds.
    2425 */
    2526const TRANSIENT_TIME = 600;
    2627
    2728/*
    28  * Set the activation hook
     29 * Set the activation hook.
    2930 */
    3031register_activation_hook( __FILE__, function ()
     
    4445
    4546        /**
    46          * Fetch a Role definition.
     47         * Fetches a role definition.
    4748         */
    4849        $role = get_role($role_name);
     
    5152
    5253            /**
    53              * Removes a capability from a role
     54             * Removes a capability from a role.
    5455             */
    5556            $role->remove_cap($capability);
     
    5859
    5960        /**
    60          * Remove role, if it exists.
     61         * Removes the role, if it exists.
    6162         */
    6263        remove_role($role_name);
     
    6566
    6667    /**
    67      * Execute WordPress role creation for the various WordPress versions.
     68     * Executes WordPress role creation for various WordPress versions.
    6869     */
    6970    populate_roles();
    7071
    7172    /**
    72      * Set a transient to show a success message
    73      */ 
    74     set_transient(TRANSIENT_NAME, __('Roles and Capabilities have been reset to WordPress defaults. The plugin has been deactivated.', 'reset-roles-and-capabilities'), TRANSIENT_TIME);
     73     * Sets a transient to show a success message.
     74     */
     75    set_transient(TRANSIENT_NAME, __('The roles and capabilities have been reset to WordPress defaults, and the plugin has been deactivated.', 'reset-roles-and-capabilities'), TRANSIENT_TIME);
    7576
    7677});
     
    7879 
    7980/**
    80  * Back compatibility
    81  * WordPress < 4.6
     81 * Backward compatibility for WordPress < 4.6.
    8282 * @link https://developer.wordpress.org/plugins/internationalization/how-to-internationalize-your-plugin/#loading-text-domain
    8383 */
     
    8989
    9090/**
    91  * Hide default admin notice on plugin activation
     91 * Hides the default admin notice on plugin activation.
    9292 */
    9393add_action( 'admin_head', function()
     
    9797
    9898/**
    99  * Show a message after activation and then delete the transient
     99 * Shows a message after activation and then deletes the transient.
    100100 */
    101101add_action('admin_notices', function ()
     
    116116
    117117/**
    118  * Deactivate the plugin
     118 * Deactivates the plugin.
    119119 */
    120120add_action('admin_init', function ()
Note: See TracChangeset for help on using the changeset viewer.