Changeset 3442367
- Timestamp:
- 01/19/2026 09:57:12 AM (2 months ago)
- Location:
- wp-attachments
- Files:
-
- 6 edited
- 1 copied
-
tags/5.2.1 (copied) (copied from wp-attachments/trunk)
-
tags/5.2.1/inc/meta-box.php (modified) (1 diff)
-
tags/5.2.1/readme.txt (modified) (2 diffs)
-
tags/5.2.1/wp-attachments.php (modified) (3 diffs)
-
trunk/inc/meta-box.php (modified) (1 diff)
-
trunk/readme.txt (modified) (2 diffs)
-
trunk/wp-attachments.php (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
wp-attachments/tags/5.2.1/inc/meta-box.php
r3308377 r3442367 388 388 wp_send_json_error('Missing data'); 389 389 } 390 391 // Object-level authorization: verify user can edit both the target post and the attachment 392 if (!current_user_can('edit_post', $post_id)) { 393 wp_send_json_error('Permission denied: cannot edit target post'); 394 } 395 if (!current_user_can('edit_post', $attachment_id)) { 396 wp_send_json_error('Permission denied: cannot edit attachment'); 397 } 398 390 399 wp_update_post(array( 391 400 'ID' => $attachment_id, -
wp-attachments/tags/5.2.1/readme.txt
r3308377 r3442367 5 5 Requires at least: 4.4 6 6 Tested up to: 6.9 7 Version: 5.2 8 Stable tag: 5.2 7 Version: 5.2.1 8 Stable tag: 5.2.1 9 9 License: GPLv2 or later 10 10 License URI: http://www.gnu.org/licenses/gpl-2.0.html … … 91 91 == Changelog == 92 92 93 94 = 5.2.1 2026-01-19 = 95 * Minor fixes and improvements. 96 93 97 = 5.2 2025-06-09 = 94 98 * Fixed regression with images (thanks @reesher + @steeltape for feedback) -
wp-attachments/tags/5.2.1/wp-attachments.php
r3308377 r3442367 6 6 Author: Marco Milesi 7 7 Author URI: https://www.marcomilesi.com 8 Version: 5.2 8 Version: 5.2.1 9 9 Text Domain: wp-attachments 10 10 */ … … 12 12 require_once( plugin_dir_path(__FILE__) . 'inc/attach_unattach_reattach.php' ); 13 13 14 function wpa_action_init() {14 add_action('init', function () { 15 15 load_plugin_textdomain( 'wp-attachments' ); 16 16 … … 40 40 $wpa_ict = (int) get_option('wpa_ict', 0); 41 41 wp_enqueue_style('wpa-css', plugin_dir_url(__FILE__) . 'styles/' . $wpa_ict . '/wpa.css'); 42 } 43 add_action('init', 'wpa_action_init'); 42 } ); 44 43 45 44 add_action('admin_init', function() { -
wp-attachments/trunk/inc/meta-box.php
r3308377 r3442367 388 388 wp_send_json_error('Missing data'); 389 389 } 390 391 // Object-level authorization: verify user can edit both the target post and the attachment 392 if (!current_user_can('edit_post', $post_id)) { 393 wp_send_json_error('Permission denied: cannot edit target post'); 394 } 395 if (!current_user_can('edit_post', $attachment_id)) { 396 wp_send_json_error('Permission denied: cannot edit attachment'); 397 } 398 390 399 wp_update_post(array( 391 400 'ID' => $attachment_id, -
wp-attachments/trunk/readme.txt
r3308377 r3442367 5 5 Requires at least: 4.4 6 6 Tested up to: 6.9 7 Version: 5.2 8 Stable tag: 5.2 7 Version: 5.2.1 8 Stable tag: 5.2.1 9 9 License: GPLv2 or later 10 10 License URI: http://www.gnu.org/licenses/gpl-2.0.html … … 91 91 == Changelog == 92 92 93 94 = 5.2.1 2026-01-19 = 95 * Minor fixes and improvements. 96 93 97 = 5.2 2025-06-09 = 94 98 * Fixed regression with images (thanks @reesher + @steeltape for feedback) -
wp-attachments/trunk/wp-attachments.php
r3308377 r3442367 6 6 Author: Marco Milesi 7 7 Author URI: https://www.marcomilesi.com 8 Version: 5.2 8 Version: 5.2.1 9 9 Text Domain: wp-attachments 10 10 */ … … 12 12 require_once( plugin_dir_path(__FILE__) . 'inc/attach_unattach_reattach.php' ); 13 13 14 function wpa_action_init() {14 add_action('init', function () { 15 15 load_plugin_textdomain( 'wp-attachments' ); 16 16 … … 40 40 $wpa_ict = (int) get_option('wpa_ict', 0); 41 41 wp_enqueue_style('wpa-css', plugin_dir_url(__FILE__) . 'styles/' . $wpa_ict . '/wpa.css'); 42 } 43 add_action('init', 'wpa_action_init'); 42 } ); 44 43 45 44 add_action('admin_init', function() {
Note: See TracChangeset
for help on using the changeset viewer.