Changeset 6141 for trunk/src/includes/topics/functions.php
- Timestamp:
- 12/08/2016 04:14:17 PM (9 years ago)
- File:
-
- 1 edited
-
trunk/src/includes/topics/functions.php (modified) (13 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/includes/topics/functions.php
r6140 r6141 163 163 // User cannot create topics 164 164 if ( ! current_user_can( 'publish_topics' ) ) { 165 bbp_add_error( 'bbp_topic_permission s', __( '<strong>ERROR</strong>: You do not have permission to create new topics.', 'bbpress' ) );165 bbp_add_error( 'bbp_topic_permission', __( '<strong>ERROR</strong>: You do not have permission to create new topics.', 'bbpress' ) ); 166 166 return; 167 167 } … … 505 505 // User cannot edit this topic 506 506 if ( ! current_user_can( 'edit_topic', $topic_id ) ) { 507 bbp_add_error( 'bbp_edit_topic_permission s', __( '<strong>ERROR</strong>: You do not have permission to edit that topic.', 'bbpress' ) );507 bbp_add_error( 'bbp_edit_topic_permission', __( '<strong>ERROR</strong>: You do not have permission to edit that topic.', 'bbpress' ) ); 508 508 } 509 509 … … 1233 1233 // Cannot edit source topic 1234 1234 if ( ! current_user_can( 'edit_topic', $source_topic->ID ) ) { 1235 bbp_add_error( 'bbp_merge_topic_source_permission', __( '<strong>ERROR</strong>: You do not have the permissionsto edit the source topic.', 'bbpress' ) );1235 bbp_add_error( 'bbp_merge_topic_source_permission', __( '<strong>ERROR</strong>: You do not have permission to edit the source topic.', 'bbpress' ) ); 1236 1236 return; 1237 1237 } … … 1253 1253 // Cannot edit destination topic 1254 1254 if ( ! current_user_can( 'edit_topic', $destination_topic->ID ) ) { 1255 bbp_add_error( 'bbp_merge_topic_destination_permission', __( '<strong>ERROR</strong>: You do not have the permissionsto edit the destination topic.', 'bbpress' ) );1255 bbp_add_error( 'bbp_merge_topic_destination_permission', __( '<strong>ERROR</strong>: You do not have permission to edit the destination topic.', 'bbpress' ) ); 1256 1256 } 1257 1257 … … 1512 1512 1513 1513 if ( empty( $_POST['bbp_reply_id'] ) ) { 1514 bbp_add_error( 'bbp_split_topic_reply_id', __( '<strong>ERROR</strong>: Reply ID to split the topic from not found!', 'bbpress' ) );1514 bbp_add_error( 'bbp_split_topic_reply_id', __( '<strong>ERROR</strong>: A reply ID is required.', 'bbpress' ) ); 1515 1515 } else { 1516 1516 $from_reply_id = (int) $_POST['bbp_reply_id']; … … 1542 1542 // Use cannot edit topic 1543 1543 if ( ! current_user_can( 'edit_topic', $source_topic->ID ) ) { 1544 bbp_add_error( 'bbp_split_topic_source_permission', __( '<strong>ERROR</strong>: You do not have the permissionsto edit the source topic.', 'bbpress' ) );1544 bbp_add_error( 'bbp_split_topic_source_permission', __( '<strong>ERROR</strong>: You do not have permission to edit the source topic.', 'bbpress' ) ); 1545 1545 } 1546 1546 … … 1565 1565 // Get destination topic id 1566 1566 if ( empty( $_POST['bbp_destination_topic'] ) ) { 1567 bbp_add_error( 'bbp_split_topic_destination_id', __( '<strong>ERROR</strong>: Destination topic ID not found!', 'bbpress' ) );1567 bbp_add_error( 'bbp_split_topic_destination_id', __( '<strong>ERROR</strong>: A topic ID is required.', 'bbpress' ) ); 1568 1568 } else { 1569 1569 $destination_topic_id = (int) $_POST['bbp_destination_topic']; … … 1575 1575 // No destination topic 1576 1576 if ( empty( $destination_topic ) ) { 1577 bbp_add_error( 'bbp_split_topic_destination_not_found', __( '<strong>ERROR</strong>: The topic you want to split to was not found !', 'bbpress' ) );1577 bbp_add_error( 'bbp_split_topic_destination_not_found', __( '<strong>ERROR</strong>: The topic you want to split to was not found.', 'bbpress' ) ); 1578 1578 } 1579 1579 1580 1580 // User cannot edit the destination topic 1581 1581 if ( ! current_user_can( 'edit_topic', $destination_topic->ID ) ) { 1582 bbp_add_error( 'bbp_split_topic_destination_permission', __( '<strong>ERROR</strong>: You do not have the permissions to edit the destination topic!', 'bbpress' ) );1582 bbp_add_error( 'bbp_split_topic_destination_permission', __( '<strong>ERROR</strong>: You do not have permission to edit the destination topic.', 'bbpress' ) ); 1583 1583 } 1584 1584 … … 1623 1623 // User cannot publish posts 1624 1624 } else { 1625 bbp_add_error( 'bbp_split_topic_destination_permission', __( '<strong>ERROR</strong>: You do not have the permissionsto create new topics. The reply could not be converted into a topic.', 'bbpress' ) );1625 bbp_add_error( 'bbp_split_topic_destination_permission', __( '<strong>ERROR</strong>: You do not have permission to create new topics. The reply could not be converted into a topic.', 'bbpress' ) ); 1626 1626 } 1627 1627 … … 1898 1898 // Can user edit topic tags? 1899 1899 if ( ! current_user_can( 'edit_topic_tags' ) ) { 1900 bbp_add_error( 'bbp_manage_topic_tag_update_permission s', __( '<strong>ERROR</strong>: You do not have the permissionsto edit the topic tags.', 'bbpress' ) );1900 bbp_add_error( 'bbp_manage_topic_tag_update_permission', __( '<strong>ERROR</strong>: You do not have permission to edit the topic tags.', 'bbpress' ) ); 1901 1901 return; 1902 1902 } … … 1938 1938 // Can user edit topic tags? 1939 1939 if ( ! current_user_can( 'edit_topic_tags' ) ) { 1940 bbp_add_error( 'bbp_manage_topic_tag_merge_permission s', __( '<strong>ERROR</strong>: You do not have the permissionsto edit the topic tags.', 'bbpress' ) );1940 bbp_add_error( 'bbp_manage_topic_tag_merge_permission', __( '<strong>ERROR</strong>: You do not have permission to edit the topic tags.', 'bbpress' ) ); 1941 1941 return; 1942 1942 } … … 1996 1996 // Can user delete topic tags? 1997 1997 if ( ! current_user_can( 'delete_topic_tags' ) ) { 1998 bbp_add_error( 'bbp_manage_topic_tag_delete_permission s', __( '<strong>ERROR</strong>: You do not have the permissionsto delete the topic tags.', 'bbpress' ) );1998 bbp_add_error( 'bbp_manage_topic_tag_delete_permission', __( '<strong>ERROR</strong>: You do not have permission to delete the topic tags.', 'bbpress' ) ); 1999 1999 return; 2000 2000 } … … 2168 2168 // What is the user doing here? 2169 2169 if ( ! current_user_can( 'edit_topic', $topic->ID ) || ( 'bbp_toggle_topic_trash' === $action && ! current_user_can( 'delete_topic', $topic->ID ) ) ) { 2170 bbp_add_error( 'bbp_toggle_topic_permission', __( '<strong>ERROR:</strong> You do not have thepermission to do that.', 'bbpress' ) );2170 bbp_add_error( 'bbp_toggle_topic_permission', __( '<strong>ERROR:</strong> You do not have permission to do that.', 'bbpress' ) ); 2171 2171 return; 2172 2172 }
Note: See TracChangeset
for help on using the changeset viewer.