Changeset 13443 for trunk/src/bp-messages/actions/delete.php
- Timestamp:
- 03/31/2023 05:26:39 PM (2 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/bp-messages/actions/delete.php
r13096 r13443 19 19 } 20 20 21 $thread_id = bp_action_variable( 1 ); 21 $thread_id = bp_action_variable( 1 ); 22 $path_chunks = bp_members_get_path_chunks( array( bp_get_messages_slug(), bp_current_action() ) ); 23 $redirect = bp_displayed_user_url( $path_chunks ); 22 24 23 25 if ( ! $thread_id || ! is_numeric( $thread_id ) || ! messages_check_thread_access( $thread_id ) ) { 24 bp_core_redirect( trailingslashit( bp_displayed_user_domain() . bp_get_messages_slug() . '/' . bp_current_action() ));26 bp_core_redirect( $redirect ); 25 27 } else { 26 28 if ( ! check_admin_referer( 'messages_delete_thread' ) ) { … … 34 36 bp_core_add_message( __('Message deleted.', 'buddypress') ); 35 37 } 36 bp_core_redirect( trailingslashit( bp_displayed_user_domain() . bp_get_messages_slug() . '/' . bp_current_action() ));38 bp_core_redirect( $redirect ); 37 39 } 38 40 }
Note: See TracChangeset
for help on using the changeset viewer.