Changeset 2870773
- Timestamp:
- 02/24/2023 09:00:33 PM (3 years ago)
- Location:
- bring-back-the-get-shortlink-button
- Files:
-
- 4 added
- 2 edited
-
tags/2.1.0 (added)
-
tags/2.1.0/bring-back-the-get-shortlink-button.php (added)
-
tags/2.1.0/license.txt (added)
-
tags/2.1.0/readme.txt (added)
-
trunk/bring-back-the-get-shortlink-button.php (modified) (2 diffs)
-
trunk/readme.txt (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
bring-back-the-get-shortlink-button/trunk/bring-back-the-get-shortlink-button.php
r2870501 r2870773 12 12 * Plugin URI: https://wordpress.org/plugins/bring-back-the-get-shortlink-button/ 13 13 * Description: This plugin brings back the Get Shortlink button, which is hidden by default since WordPress 4.4. 14 * Version: 2. 0.014 * Version: 2.1.0 15 15 * Requires at least: 4.4 16 16 * Requires PHP: 7.4 … … 22 22 */ 23 23 24 if ( ! function_exists( 'add_filter' ) ) { 24 namespace tfrommen\BringBackTheGetShortlinkButton; 25 26 if ( ! function_exists( 'add_action' ) ) { 25 27 return; 26 28 } 27 29 28 add_filter( 'get_shortlink', function ( string $shortlink ): string { 30 /** 31 * Bootstrap the plugin. 32 * 33 * @return void 34 */ 35 function bootstrap(): void { 36 37 add_filter( 'get_shortlink', __NAMESPACE__ . '\\pass_through' ); 38 } 39 40 /** 41 * Simple pass-through callback for the shortlink filter. 42 * 43 * @param string $shortlink Shortlink. 44 * 45 * @return string Shortlink. 46 */ 47 function pass_through( string $shortlink ): string { 29 48 30 49 return $shortlink; 31 } ); 50 } 51 52 add_action( 'plugins_loaded', __NAMESPACE__ . '\\bootstrap' ); -
bring-back-the-get-shortlink-button/trunk/readme.txt
r2870501 r2870773 5 5 Tested up to: 6.1 6 6 Requires PHP: 7.4 7 Stable tag: 2. 0.07 Stable tag: 2.1.0 8 8 License: GPL v3 or later 9 9 License URI: https://www.gnu.org/licenses/gpl-3.0.txt … … 27 27 == Changelog == 28 28 29 = 2.1.0 = 30 * Add unit tests. 31 * Split main plugin file into multiple functions to allow for better testability. 32 * Rename folder including WordPress.org assets. 33 29 34 = 2.0.0 = 30 35 * Add type declarations. … … 37 42 38 43 = 1.1.0 = 39 *WordPress.org release.44 WordPress.org release. 40 45 41 46 = 1.0.0 = 42 *Initial release.47 Initial release.
Note: See TracChangeset
for help on using the changeset viewer.