BuddyPress - Version 5.0.0-beta2

Version Description

= 4.4.0 = See: https://codex.buddypress.org/releases/version-4-4-0/

= 4.3.0 = See: https://codex.buddypress.org/releases/version-4-3-0/

= 4.2.0 = See: https://codex.buddypress.org/releases/version-4-2-0/

= 4.1.0 = See: https://codex.buddypress.org/releases/version-4-1-0/

= 4.0.0 = See: https://codex.buddypress.org/releases/version-4-0-0/

Download this release

Release Info

Developer imath
Plugin Icon 128x128 BuddyPress
Version 5.0.0-beta2
Comparing to
See all releases

Code changes from version 5.0.0-beta1 to 5.0.0-beta2

bp-activity/classes/class-bp-rest-activity-endpoint.php CHANGED
@@ -574,7 +574,7 @@ class BP_REST_Activity_Endpoint extends WP_REST_Controller {
574
  if ( true === $retval && empty( $activity->id ) ) {
575
  $retval = new WP_Error(
576
  'bp_rest_invalid_id',
577
- __( 'Invalid activity id.', 'buddypress' ),
578
  array(
579
  'status' => 404,
580
  )
@@ -687,7 +687,7 @@ class BP_REST_Activity_Endpoint extends WP_REST_Controller {
687
  if ( true === $retval && empty( $activity->id ) ) {
688
  $retval = new WP_Error(
689
  'bp_rest_invalid_id',
690
- __( 'Invalid activity id.', 'buddypress' ),
691
  array(
692
  'status' => 404,
693
  )
@@ -749,7 +749,7 @@ class BP_REST_Activity_Endpoint extends WP_REST_Controller {
749
  if ( empty( $activity->id ) ) {
750
  return new WP_Error(
751
  'bp_rest_invalid_id',
752
- __( 'Invalid activity id.', 'buddypress' ),
753
  array(
754
  'status' => 404,
755
  )
574
  if ( true === $retval && empty( $activity->id ) ) {
575
  $retval = new WP_Error(
576
  'bp_rest_invalid_id',
577
+ __( 'Invalid activity ID.', 'buddypress' ),
578
  array(
579
  'status' => 404,
580
  )
687
  if ( true === $retval && empty( $activity->id ) ) {
688
  $retval = new WP_Error(
689
  'bp_rest_invalid_id',
690
+ __( 'Invalid activity ID.', 'buddypress' ),
691
  array(
692
  'status' => 404,
693
  )
749
  if ( empty( $activity->id ) ) {
750
  return new WP_Error(
751
  'bp_rest_invalid_id',
752
+ __( 'Invalid activity ID.', 'buddypress' ),
753
  array(
754
  'status' => 404,
755
  )
bp-core/bp-core-rest-api.php CHANGED
@@ -18,7 +18,7 @@ defined( 'ABSPATH' ) || exit;
18
  * @return boolean True if the BP REST plugin is active. False otherwise.
19
  */
20
  function bp_rest_is_plugin_active() {
21
- return (bool) has_action( 'bp_rest_api_init', 'bp_rest', 5 );
22
  }
23
 
24
  /**
@@ -33,9 +33,9 @@ function bp_rest_is_plugin_active() {
33
  * @return bool Whether to use the REST Endpoints of built BuddyPress.
34
  */
35
  function bp_rest_in_buddypress() {
36
- $is_src = defined( 'BP_SOURCE_SUBDIRECTORY' ) && BP_SOURCE_SUBDIRECTORY === 'src';
37
 
38
- return ! $is_src && ! bp_rest_is_plugin_active();
39
  }
40
 
41
  /**
@@ -47,16 +47,16 @@ function bp_rest_in_buddypress() {
47
  */
48
  function bp_rest_api_is_available() {
49
 
50
- /**
51
- * Filter here to disable the BP REST API.
52
- *
53
- * The BP REST API requires at least WordPress 4.7.0
54
- *
55
- * @since 5.0.0
56
- *
57
- * @param boolean $value True if the BP REST API is available. False otherwise.
58
- */
59
- return apply_filters( 'bp_rest_api_is_available', function_exists( 'create_initial_rest_routes' ) && bp_rest_in_buddypress() ) || bp_rest_is_plugin_active();
60
  }
61
 
62
  /**
@@ -65,32 +65,34 @@ function bp_rest_api_is_available() {
65
  * @since 5.0.0
66
  */
67
  function bp_rest_api_register_request_script() {
68
- if ( ! bp_rest_api_is_available() ) {
69
- return;
70
- }
71
-
72
- $dependencies = array( 'jquery' );
73
-
74
- // The wrapper for WP REST API requests was introduced in WordPress 4.9.0
75
- if ( wp_script_is( 'wp-api-request', 'registered' ) ) {
76
- $dependencies = array( 'wp-api-request' );
77
- }
78
-
79
- wp_register_script(
80
- 'bp-api-request',
81
- sprintf( '%1$sbp-core/js/bp-api-request%2$s.js', buddypress()->plugin_url, bp_core_get_minified_asset_suffix() ),
82
- $dependencies,
83
- bp_get_version(),
84
- true
85
- );
86
- wp_localize_script(
87
- 'bp-api-request',
88
- 'bpApiSettings',
89
- array(
90
- 'root' => esc_url_raw( get_rest_url() ),
91
- 'nonce' => wp_create_nonce( 'wp_rest' ),
92
- )
93
- );
 
 
94
  }
95
  add_action( 'bp_init', 'bp_rest_api_register_request_script' );
96
 
@@ -236,10 +238,10 @@ function bp_rest_validate_member_types( $value ) {
236
  foreach ( $types as $type ) {
237
  if ( ! in_array( $type, $registered_types, true ) ) {
238
  return new WP_Error(
239
- 'bp_rest_invalid_group_type',
240
  sprintf(
241
  /* translators: %1$s and %2$s is replaced with the registered type(s) */
242
- __( 'The member type you provided, %$1s, is not one of %$2s.', 'buddypress' ),
243
  $type,
244
  implode( ', ', $registered_types )
245
  )
18
  * @return boolean True if the BP REST plugin is active. False otherwise.
19
  */
20
  function bp_rest_is_plugin_active() {
21
+ return (bool) has_action( 'bp_rest_api_init', 'bp_rest', 5 );
22
  }
23
 
24
  /**
33
  * @return bool Whether to use the REST Endpoints of built BuddyPress.
34
  */
35
  function bp_rest_in_buddypress() {
36
+ $is_src = defined( 'BP_SOURCE_SUBDIRECTORY' ) && BP_SOURCE_SUBDIRECTORY === 'src';
37
 
38
+ return ! $is_src && ! bp_rest_is_plugin_active();
39
  }
40
 
41
  /**
47
  */
48
  function bp_rest_api_is_available() {
49
 
50
+ /**
51
+ * Filter here to disable the BP REST API.
52
+ *
53
+ * The BP REST API requires at least WordPress 4.7.0
54
+ *
55
+ * @since 5.0.0
56
+ *
57
+ * @param boolean $value True if the BP REST API is available. False otherwise.
58
+ */
59
+ return apply_filters( 'bp_rest_api_is_available', function_exists( 'create_initial_rest_routes' ) && bp_rest_in_buddypress() ) || bp_rest_is_plugin_active();
60
  }
61
 
62
  /**
65
  * @since 5.0.0
66
  */
67
  function bp_rest_api_register_request_script() {
68
+ if ( ! bp_rest_api_is_available() ) {
69
+ return;
70
+ }
71
+
72
+ $dependencies = array( 'jquery' );
73
+
74
+ // The wrapper for WP REST API requests was introduced in WordPress 4.9.0.
75
+ if ( wp_script_is( 'wp-api-request', 'registered' ) ) {
76
+ $dependencies = array( 'wp-api-request' );
77
+ }
78
+
79
+ wp_register_script(
80
+ 'bp-api-request',
81
+ sprintf( '%1$sbp-core/js/bp-api-request%2$s.js', buddypress()->plugin_url, bp_core_get_minified_asset_suffix() ),
82
+ $dependencies,
83
+ bp_get_version(),
84
+ true
85
+ );
86
+
87
+ wp_localize_script(
88
+ 'bp-api-request',
89
+ 'bpApiSettings',
90
+ array(
91
+ 'root' => esc_url_raw( get_rest_url() ),
92
+ 'nonce' => wp_create_nonce( 'wp_rest' ),
93
+ 'unexpectedError' => __( 'An unexpected error occured. Please try again.', 'buddypress' ),
94
+ )
95
+ );
96
  }
97
  add_action( 'bp_init', 'bp_rest_api_register_request_script' );
98
 
238
  foreach ( $types as $type ) {
239
  if ( ! in_array( $type, $registered_types, true ) ) {
240
  return new WP_Error(
241
+ 'bp_rest_invalid_member_type',
242
  sprintf(
243
  /* translators: %1$s and %2$s is replaced with the registered type(s) */
244
+ __( 'The member type you provided, %1$s, is not one of %2$s.', 'buddypress' ),
245
  $type,
246
  implode( ', ', $registered_types )
247
  )
bp-core/classes/class-bp-rest-attachments-group-avatar-endpoint.php CHANGED
@@ -175,7 +175,7 @@ class BP_REST_Attachments_Group_Avatar_Endpoint extends WP_REST_Controller {
175
  if ( ! $this->group ) {
176
  $retval = new WP_Error(
177
  'bp_rest_group_invalid_id',
178
- __( 'Invalid group id.', 'buddypress' ),
179
  array(
180
  'status' => 404,
181
  )
@@ -272,7 +272,7 @@ class BP_REST_Attachments_Group_Avatar_Endpoint extends WP_REST_Controller {
272
  ) {
273
  $retval = new WP_Error(
274
  'bp_rest_authorization_required',
275
- __( 'Sorry, you are unauthorized to perform this action.', 'buddypress' ),
276
  array(
277
  'status' => rest_authorization_required_code(),
278
  )
175
  if ( ! $this->group ) {
176
  $retval = new WP_Error(
177
  'bp_rest_group_invalid_id',
178
+ __( 'Invalid group ID.', 'buddypress' ),
179
  array(
180
  'status' => 404,
181
  )
272
  ) {
273
  $retval = new WP_Error(
274
  'bp_rest_authorization_required',
275
+ __( 'Sorry, you are not authorized to perform this action.', 'buddypress' ),
276
  array(
277
  'status' => rest_authorization_required_code(),
278
  )
bp-core/classes/class-bp-rest-attachments-member-avatar-endpoint.php CHANGED
@@ -166,7 +166,7 @@ class BP_REST_Attachments_Member_Avatar_Endpoint extends WP_REST_Controller {
166
  if ( true === $retval && ! $this->user instanceof WP_User ) {
167
  $retval = new WP_Error(
168
  'bp_rest_member_invalid_id',
169
- __( 'Invalid member id.', 'buddypress' ),
170
  array(
171
  'status' => 404,
172
  )
166
  if ( true === $retval && ! $this->user instanceof WP_User ) {
167
  $retval = new WP_Error(
168
  'bp_rest_member_invalid_id',
169
+ __( 'Invalid member ID.', 'buddypress' ),
170
  array(
171
  'status' => 404,
172
  )
bp-core/classes/trait-attachments.php CHANGED
@@ -172,8 +172,8 @@ trait BP_REST_Attachments {
172
  return new WP_Error(
173
  "bp_rest_attachments_{$this->object}_avatar_upload_error",
174
  sprintf(
175
- /* translators: %$1s is replaced with error message. */
176
- __( 'Upload failed! Error was: %$1s', 'buddypress' ),
177
  $img_dir->get_error_message()
178
  ),
179
  array(
@@ -248,7 +248,7 @@ trait BP_REST_Attachments {
248
  return new WP_Error(
249
  "bp_rest_attachments_{$this->object}_avatar_crop_error",
250
  sprintf(
251
- /* translators: %$1s is replaced with object type. */
252
  __( 'There was a problem cropping your %s photo.', 'buddypress' ),
253
  $this->object
254
  ),
172
  return new WP_Error(
173
  "bp_rest_attachments_{$this->object}_avatar_upload_error",
174
  sprintf(
175
+ /* translators: %s is replaced with error message. */
176
+ __( 'Upload failed! Error was: %s', 'buddypress' ),
177
  $img_dir->get_error_message()
178
  ),
179
  array(
248
  return new WP_Error(
249
  "bp_rest_attachments_{$this->object}_avatar_crop_error",
250
  sprintf(
251
+ /* translators: %s is replaced with object type. */
252
  __( 'There was a problem cropping your %s photo.', 'buddypress' ),
253
  $this->object
254
  ),
bp-core/js/bp-api-request.js CHANGED
@@ -17,13 +17,15 @@ window.bp = window.bp || {};
17
 
18
  // Polyfill wp.apiRequest if WordPress < 4.9
19
  bp.apiRequest = function( options ) {
 
 
20
  if ( ! options.dataType ) {
21
  options.dataType = 'json';
22
  }
23
 
24
  // WordPress is >= 4.9.0.
25
  if ( wp.apiRequest ) {
26
- return wp.apiRequest( options );
27
 
28
  // WordPress is < 4.9.0.
29
  } else {
@@ -33,13 +35,35 @@ window.bp = window.bp || {};
33
  url = url + options.path.replace( /^\//, '' );
34
  }
35
 
36
- options.url = url;
37
- options.beforeSend = function( xhr ) {
38
- xhr.setRequestHeader( 'X-WP-Nonce', bpApiSettings.nonce );
39
- };
 
 
 
 
 
 
40
 
41
- return $.ajax( options );
42
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
43
  };
44
 
45
  } )( window.wp || {}, window.bp, jQuery );
17
 
18
  // Polyfill wp.apiRequest if WordPress < 4.9
19
  bp.apiRequest = function( options ) {
20
+ var bpRequest;
21
+
22
  if ( ! options.dataType ) {
23
  options.dataType = 'json';
24
  }
25
 
26
  // WordPress is >= 4.9.0.
27
  if ( wp.apiRequest ) {
28
+ bpRequest = wp.apiRequest( options );
29
 
30
  // WordPress is < 4.9.0.
31
  } else {
35
  url = url + options.path.replace( /^\//, '' );
36
  }
37
 
38
+ if ( ! options.url ) {
39
+ options.url = url;
40
+ }
41
+
42
+ // Add The nonce only when needed.
43
+ if ( -1 !== options.url.indexOf( url ) ) {
44
+ options.beforeSend = function( xhr ) {
45
+ xhr.setRequestHeader( 'X-WP-Nonce', bpApiSettings.nonce );
46
+ };
47
+ }
48
 
49
+ bpRequest = $.ajax( options );
50
  }
51
+
52
+ return bpRequest.then( null, function( result ) {
53
+ var errorObject = {
54
+ code: 'unexpected_error',
55
+ message: bpApiSettings.unexpectedError,
56
+ data: {
57
+ status: 404
58
+ }
59
+ };
60
+
61
+ if ( result && result.responseJSON ) {
62
+ errorObject = result.responseJSON;
63
+ }
64
+
65
+ return errorObject;
66
+ } );
67
  };
68
 
69
  } )( window.wp || {}, window.bp, jQuery );
bp-core/js/bp-api-request.min.js CHANGED
@@ -1 +1 @@
1
- window.bp=window.bp||{},function(e,n,t){"undefined"!=typeof bpApiSettings&&(n.isRestEnabled=!0,n.apiRequest=function(n){if(n.dataType||(n.dataType="json"),e.apiRequest)return e.apiRequest(n);var i=bpApiSettings.root;return n.path&&(i+=n.path.replace(/^\//,"")),n.url=i,n.beforeSend=function(e){e.setRequestHeader("X-WP-Nonce",bpApiSettings.nonce)},t.ajax(n)})}(window.wp||{},window.bp,jQuery);
1
+ window.bp=window.bp||{},function(e,n,t){"undefined"!=typeof bpApiSettings&&(n.isRestEnabled=!0,n.apiRequest=function(n){var p;if(n.dataType||(n.dataType="json"),e.apiRequest)p=e.apiRequest(n);else{var i=bpApiSettings.root;n.path&&(i+=n.path.replace(/^\//,"")),n.url||(n.url=i),-1!==n.url.indexOf(i)&&(n.beforeSend=function(e){e.setRequestHeader("X-WP-Nonce",bpApiSettings.nonce)}),p=t.ajax(n)}return p.then(null,function(e){var n={code:"unexpected_error",message:bpApiSettings.unexpectedError,data:{status:404}};return e&&e.responseJSON&&(n=e.responseJSON),n})})}(window.wp||{},window.bp,jQuery);
bp-groups/classes/class-bp-rest-group-invites-endpoint.php CHANGED
@@ -208,7 +208,7 @@ class BP_REST_Group_Invites_Endpoint extends WP_REST_Controller {
208
  if ( true === $retval && $request['group_id'] && ! $group instanceof BP_Groups_Group ) {
209
  $retval = new WP_Error(
210
  'bp_rest_group_invalid_id',
211
- __( 'Invalid group id.', 'buddypress' ),
212
  array(
213
  'status' => 404,
214
  )
@@ -219,7 +219,7 @@ class BP_REST_Group_Invites_Endpoint extends WP_REST_Controller {
219
  if ( true === $retval && $user_id_arg && ! $user instanceof WP_User ) {
220
  $retval = new WP_Error(
221
  'bp_rest_member_invalid_id',
222
- __( 'Invalid member id.', 'buddypress' ),
223
  array(
224
  'status' => 404,
225
  )
@@ -230,7 +230,7 @@ class BP_REST_Group_Invites_Endpoint extends WP_REST_Controller {
230
  if ( true === $retval && $request['inviter_id'] && ! $inviter instanceof WP_User ) {
231
  $retval = new WP_Error(
232
  'bp_rest_member_invalid_id',
233
- __( 'Invalid member id.', 'buddypress' ),
234
  array(
235
  'status' => 404,
236
  )
@@ -328,7 +328,7 @@ class BP_REST_Group_Invites_Endpoint extends WP_REST_Controller {
328
  if ( true === $retval && ! $invite ) {
329
  $retval = new WP_Error(
330
  'bp_rest_group_invite_invalid_id',
331
- __( 'Invalid group invitation id.', 'buddypress' ),
332
  array(
333
  'status' => 404,
334
  )
@@ -458,7 +458,7 @@ class BP_REST_Group_Invites_Endpoint extends WP_REST_Controller {
458
  if ( true === $retval && empty( $group->id ) ) {
459
  $retval = new WP_Error(
460
  'bp_rest_group_invalid_id',
461
- __( 'Invalid group id.', 'buddypress' ),
462
  array(
463
  'status' => 404,
464
  )
@@ -468,7 +468,7 @@ class BP_REST_Group_Invites_Endpoint extends WP_REST_Controller {
468
  if ( true === $retval && ( empty( $user->ID ) || empty( $inviter->ID ) || $user->ID === $inviter->ID ) ) {
469
  $retval = new WP_Error(
470
  'bp_rest_member_invalid_id',
471
- __( 'Invalid member id.', 'buddypress' ),
472
  array(
473
  'status' => 404,
474
  )
@@ -573,7 +573,7 @@ class BP_REST_Group_Invites_Endpoint extends WP_REST_Controller {
573
  if ( true === $retval && ! $invite ) {
574
  $retval = new WP_Error(
575
  'bp_rest_group_invite_invalid_id',
576
- __( 'Invalid group invitation id.', 'buddypress' ),
577
  array(
578
  'status' => 404,
579
  )
@@ -699,7 +699,7 @@ class BP_REST_Group_Invites_Endpoint extends WP_REST_Controller {
699
  if ( true === $retval && ! $invite ) {
700
  $retval = new WP_Error(
701
  'bp_rest_group_invite_invalid_id',
702
- __( 'Invalid group invitation id.', 'buddypress' ),
703
  array(
704
  'status' => 404,
705
  )
208
  if ( true === $retval && $request['group_id'] && ! $group instanceof BP_Groups_Group ) {
209
  $retval = new WP_Error(
210
  'bp_rest_group_invalid_id',
211
+ __( 'Invalid group ID.', 'buddypress' ),
212
  array(
213
  'status' => 404,
214
  )
219
  if ( true === $retval && $user_id_arg && ! $user instanceof WP_User ) {
220
  $retval = new WP_Error(
221
  'bp_rest_member_invalid_id',
222
+ __( 'Invalid member ID.', 'buddypress' ),
223
  array(
224
  'status' => 404,
225
  )
230
  if ( true === $retval && $request['inviter_id'] && ! $inviter instanceof WP_User ) {
231
  $retval = new WP_Error(
232
  'bp_rest_member_invalid_id',
233
+ __( 'Invalid member ID.', 'buddypress' ),
234
  array(
235
  'status' => 404,
236
  )
328
  if ( true === $retval && ! $invite ) {
329
  $retval = new WP_Error(
330
  'bp_rest_group_invite_invalid_id',
331
+ __( 'Invalid group invitation ID.', 'buddypress' ),
332
  array(
333
  'status' => 404,
334
  )
458
  if ( true === $retval && empty( $group->id ) ) {
459
  $retval = new WP_Error(
460
  'bp_rest_group_invalid_id',
461
+ __( 'Invalid group ID.', 'buddypress' ),
462
  array(
463
  'status' => 404,
464
  )
468
  if ( true === $retval && ( empty( $user->ID ) || empty( $inviter->ID ) || $user->ID === $inviter->ID ) ) {
469
  $retval = new WP_Error(
470
  'bp_rest_member_invalid_id',
471
+ __( 'Invalid member ID.', 'buddypress' ),
472
  array(
473
  'status' => 404,
474
  )
573
  if ( true === $retval && ! $invite ) {
574
  $retval = new WP_Error(
575
  'bp_rest_group_invite_invalid_id',
576
+ __( 'Invalid group invitation ID.', 'buddypress' ),
577
  array(
578
  'status' => 404,
579
  )
699
  if ( true === $retval && ! $invite ) {
700
  $retval = new WP_Error(
701
  'bp_rest_group_invite_invalid_id',
702
+ __( 'Invalid group invitation ID.', 'buddypress' ),
703
  array(
704
  'status' => 404,
705
  )
bp-groups/classes/class-bp-rest-group-membership-endpoint.php CHANGED
@@ -310,7 +310,7 @@ class BP_REST_Group_Membership_Endpoint extends WP_REST_Controller {
310
  if ( true === $retval && ! $user instanceof WP_User ) {
311
  $retval = new WP_Error(
312
  'bp_rest_group_member_invalid_id',
313
- __( 'Invalid group member id.', 'buddypress' ),
314
  array(
315
  'status' => 404,
316
  )
@@ -321,7 +321,7 @@ class BP_REST_Group_Membership_Endpoint extends WP_REST_Controller {
321
  if ( true === $retval && ! $group instanceof BP_Groups_Group ) {
322
  $retval = new WP_Error(
323
  'bp_rest_group_invalid_id',
324
- __( 'Invalid group id.', 'buddypress' ),
325
  array(
326
  'status' => 404,
327
  )
@@ -408,13 +408,15 @@ class BP_REST_Group_Membership_Endpoint extends WP_REST_Controller {
408
  }
409
  } elseif ( in_array( $action, [ 'demote', 'ban', 'unban' ], true ) ) {
410
  if ( ! $group_member->$action() ) {
 
 
 
 
 
 
411
  return new WP_Error(
412
  'bp_rest_group_member_failed_to_' . $action,
413
- sprintf(
414
- /* translators: %1$s is replaced with the action */
415
- __( 'Could not %s member from the group.', 'buddypress' ),
416
- esc_attr( $action )
417
- ),
418
  array(
419
  'status' => 500,
420
  )
@@ -475,7 +477,7 @@ class BP_REST_Group_Membership_Endpoint extends WP_REST_Controller {
475
  if ( true === $retval && ! $user instanceof WP_User ) {
476
  $retval = new WP_Error(
477
  'bp_rest_group_member_invalid_id',
478
- __( 'Invalid group member id.', 'buddypress' ),
479
  array(
480
  'status' => 404,
481
  )
@@ -486,7 +488,7 @@ class BP_REST_Group_Membership_Endpoint extends WP_REST_Controller {
486
  if ( true === $retval && ! $group instanceof BP_Groups_Group ) {
487
  $retval = new WP_Error(
488
  'bp_rest_group_invalid_id',
489
- __( 'Invalid group id.', 'buddypress' ),
490
  array(
491
  'status' => 404,
492
  )
@@ -501,13 +503,16 @@ class BP_REST_Group_Membership_Endpoint extends WP_REST_Controller {
501
  $loggedin_user_id = bp_loggedin_user_id();
502
  if ( true === $retval && in_array( $request['action'], [ 'ban', 'unban', 'promote', 'demote' ], true ) ) {
503
  if ( ! groups_is_user_admin( $loggedin_user_id, $group->id ) && ! groups_is_user_mod( $loggedin_user_id, $group->id ) ) {
 
 
 
 
 
 
 
504
  $retval = new WP_Error(
505
  'bp_rest_group_member_cannot_' . $request['action'],
506
- sprintf(
507
- /* translators: %1$s is replaced with the action. */
508
- __( 'Sorry, you are not allowed to %s this group member.', 'buddypress' ),
509
- esc_attr( $request['action'] )
510
- ),
511
  array(
512
  'status' => rest_authorization_required_code(),
513
  )
@@ -609,7 +614,7 @@ class BP_REST_Group_Membership_Endpoint extends WP_REST_Controller {
609
  if ( true === $retval && ! $user instanceof WP_User ) {
610
  return new WP_Error(
611
  'bp_rest_group_member_invalid_id',
612
- __( 'Invalid group member id.', 'buddypress' ),
613
  array(
614
  'status' => 404,
615
  )
@@ -620,7 +625,7 @@ class BP_REST_Group_Membership_Endpoint extends WP_REST_Controller {
620
  if ( true === $retval && ! $group instanceof BP_Groups_Group ) {
621
  $retval = new WP_Error(
622
  'bp_rest_group_invalid_id',
623
- __( 'Invalid group id.', 'buddypress' ),
624
  array(
625
  'status' => 404,
626
  )
310
  if ( true === $retval && ! $user instanceof WP_User ) {
311
  $retval = new WP_Error(
312
  'bp_rest_group_member_invalid_id',
313
+ __( 'Invalid group member ID.', 'buddypress' ),
314
  array(
315
  'status' => 404,
316
  )
321
  if ( true === $retval && ! $group instanceof BP_Groups_Group ) {
322
  $retval = new WP_Error(
323
  'bp_rest_group_invalid_id',
324
+ __( 'Invalid group ID.', 'buddypress' ),
325
  array(
326
  'status' => 404,
327
  )
408
  }
409
  } elseif ( in_array( $action, [ 'demote', 'ban', 'unban' ], true ) ) {
410
  if ( ! $group_member->$action() ) {
411
+ $messages = array(
412
+ 'demote' => __( 'Could not demote member from the group.', 'buddypress' ),
413
+ 'ban' => __( 'Could not ban member from the group.', 'buddypress' ),
414
+ 'unban' => __( 'Could not unban member from the group.', 'buddypress' ),
415
+ );
416
+
417
  return new WP_Error(
418
  'bp_rest_group_member_failed_to_' . $action,
419
+ $messages[ $action ],
 
 
 
 
420
  array(
421
  'status' => 500,
422
  )
477
  if ( true === $retval && ! $user instanceof WP_User ) {
478
  $retval = new WP_Error(
479
  'bp_rest_group_member_invalid_id',
480
+ __( 'Invalid group member ID.', 'buddypress' ),
481
  array(
482
  'status' => 404,
483
  )
488
  if ( true === $retval && ! $group instanceof BP_Groups_Group ) {
489
  $retval = new WP_Error(
490
  'bp_rest_group_invalid_id',
491
+ __( 'Invalid group ID.', 'buddypress' ),
492
  array(
493
  'status' => 404,
494
  )
503
  $loggedin_user_id = bp_loggedin_user_id();
504
  if ( true === $retval && in_array( $request['action'], [ 'ban', 'unban', 'promote', 'demote' ], true ) ) {
505
  if ( ! groups_is_user_admin( $loggedin_user_id, $group->id ) && ! groups_is_user_mod( $loggedin_user_id, $group->id ) ) {
506
+ $messages = array(
507
+ 'ban' => __( 'Sorry, you are not allowed to ban this group member.', 'buddypress' ),
508
+ 'unban' => __( 'Sorry, you are not allowed to unban this group member.', 'buddypress' ),
509
+ 'promote' => __( 'Sorry, you are not allowed to promote this group member.', 'buddypress' ),
510
+ 'demote' => __( 'Sorry, you are not allowed to demote this group member.', 'buddypress' ),
511
+ );
512
+
513
  $retval = new WP_Error(
514
  'bp_rest_group_member_cannot_' . $request['action'],
515
+ $messages[ $request['action'] ],
 
 
 
 
516
  array(
517
  'status' => rest_authorization_required_code(),
518
  )
614
  if ( true === $retval && ! $user instanceof WP_User ) {
615
  return new WP_Error(
616
  'bp_rest_group_member_invalid_id',
617
+ __( 'Invalid group member ID.', 'buddypress' ),
618
  array(
619
  'status' => 404,
620
  )
625
  if ( true === $retval && ! $group instanceof BP_Groups_Group ) {
626
  $retval = new WP_Error(
627
  'bp_rest_group_invalid_id',
628
+ __( 'Invalid group ID.', 'buddypress' ),
629
  array(
630
  'status' => 404,
631
  )
bp-groups/classes/class-bp-rest-group-membership-request-endpoint.php CHANGED
@@ -204,7 +204,7 @@ class BP_REST_Group_Membership_Request_Endpoint extends WP_REST_Controller {
204
  if ( true === $retval && $request['group_id'] && ! $group instanceof BP_Groups_Group ) {
205
  $retval = new WP_Error(
206
  'bp_rest_group_invalid_id',
207
- __( 'Invalid group id.', 'buddypress' ),
208
  array(
209
  'status' => 404,
210
  )
@@ -215,7 +215,7 @@ class BP_REST_Group_Membership_Request_Endpoint extends WP_REST_Controller {
215
  if ( true === $retval && $user_id_arg && ! $user instanceof WP_User ) {
216
  $retval = new WP_Error(
217
  'bp_rest_member_invalid_id',
218
- __( 'Invalid member id.', 'buddypress' ),
219
  array(
220
  'status' => 404,
221
  )
@@ -303,7 +303,7 @@ class BP_REST_Group_Membership_Request_Endpoint extends WP_REST_Controller {
303
  if ( true === $retval && ! $group_request ) {
304
  $retval = new WP_Error(
305
  'bp_rest_group_membership_requests_invalid_id',
306
- __( 'Invalid group membership request id.', 'buddypress' ),
307
  array(
308
  'status' => 404,
309
  )
@@ -435,7 +435,7 @@ class BP_REST_Group_Membership_Request_Endpoint extends WP_REST_Controller {
435
  if ( true === $retval && ! $user instanceof WP_User ) {
436
  $retval = new WP_Error(
437
  'bp_rest_group_member_invalid_id',
438
- __( 'Invalid user id.', 'buddypress' ),
439
  array(
440
  'status' => 404,
441
  )
@@ -446,7 +446,7 @@ class BP_REST_Group_Membership_Request_Endpoint extends WP_REST_Controller {
446
  if ( true === $retval && ! $group instanceof BP_Groups_Group ) {
447
  $retval = new WP_Error(
448
  'bp_rest_group_invalid_id',
449
- __( 'Invalid group id.', 'buddypress' ),
450
  array(
451
  'status' => 404,
452
  )
@@ -553,7 +553,7 @@ class BP_REST_Group_Membership_Request_Endpoint extends WP_REST_Controller {
553
  if ( true === $retval && ! $group_request ) {
554
  $retval = new WP_Error(
555
  'bp_rest_group_membership_requests_invalid_id',
556
- __( 'Invalid group membership request id.', 'buddypress' ),
557
  array(
558
  'status' => 404,
559
  )
@@ -679,7 +679,7 @@ class BP_REST_Group_Membership_Request_Endpoint extends WP_REST_Controller {
679
  if ( true === $retval && ! $group_request ) {
680
  $retval = new WP_Error(
681
  'bp_rest_group_membership_requests_invalid_id',
682
- __( 'Invalid group membership request id.', 'buddypress' ),
683
  array(
684
  'status' => 404,
685
  )
204
  if ( true === $retval && $request['group_id'] && ! $group instanceof BP_Groups_Group ) {
205
  $retval = new WP_Error(
206
  'bp_rest_group_invalid_id',
207
+ __( 'Invalid group ID.', 'buddypress' ),
208
  array(
209
  'status' => 404,
210
  )
215
  if ( true === $retval && $user_id_arg && ! $user instanceof WP_User ) {
216
  $retval = new WP_Error(
217
  'bp_rest_member_invalid_id',
218
+ __( 'Invalid member ID.', 'buddypress' ),
219
  array(
220
  'status' => 404,
221
  )
303
  if ( true === $retval && ! $group_request ) {
304
  $retval = new WP_Error(
305
  'bp_rest_group_membership_requests_invalid_id',
306
+ __( 'Invalid group membership request ID.', 'buddypress' ),
307
  array(
308
  'status' => 404,
309
  )
435
  if ( true === $retval && ! $user instanceof WP_User ) {
436
  $retval = new WP_Error(
437
  'bp_rest_group_member_invalid_id',
438
+ __( 'Invalid member ID.', 'buddypress' ),
439
  array(
440
  'status' => 404,
441
  )
446
  if ( true === $retval && ! $group instanceof BP_Groups_Group ) {
447
  $retval = new WP_Error(
448
  'bp_rest_group_invalid_id',
449
+ __( 'Invalid group ID.', 'buddypress' ),
450
  array(
451
  'status' => 404,
452
  )
553
  if ( true === $retval && ! $group_request ) {
554
  $retval = new WP_Error(
555
  'bp_rest_group_membership_requests_invalid_id',
556
+ __( 'Invalid group membership request ID.', 'buddypress' ),
557
  array(
558
  'status' => 404,
559
  )
679
  if ( true === $retval && ! $group_request ) {
680
  $retval = new WP_Error(
681
  'bp_rest_group_membership_requests_invalid_id',
682
+ __( 'Invalid group membership request ID.', 'buddypress' ),
683
  array(
684
  'status' => 404,
685
  )
bp-groups/classes/class-bp-rest-groups-endpoint.php CHANGED
@@ -237,7 +237,7 @@ class BP_REST_Groups_Endpoint extends WP_REST_Controller {
237
  if ( empty( $group->id ) ) {
238
  $retval = new WP_Error(
239
  'bp_rest_group_invalid_id',
240
- __( 'Invalid group id.', 'buddypress' ),
241
  array(
242
  'status' => 404,
243
  )
@@ -441,7 +441,7 @@ class BP_REST_Groups_Endpoint extends WP_REST_Controller {
441
  if ( true === $retval && empty( $group->id ) ) {
442
  $retval = new WP_Error(
443
  'bp_rest_group_invalid_id',
444
- __( 'Invalid group id.', 'buddypress' ),
445
  array(
446
  'status' => 404,
447
  )
@@ -545,7 +545,7 @@ class BP_REST_Groups_Endpoint extends WP_REST_Controller {
545
  if ( true === $retval && empty( $group->id ) ) {
546
  $retval = new WP_Error(
547
  'bp_rest_group_invalid_id',
548
- __( 'Invalid group id.', 'buddypress' ),
549
  array(
550
  'status' => 404,
551
  )
@@ -1001,7 +1001,7 @@ class BP_REST_Groups_Endpoint extends WP_REST_Controller {
1001
  ),
1002
  'enable_forum' => array(
1003
  'context' => array( 'view', 'edit' ),
1004
- 'description' => __( 'Whether the Group has a forum or not.', 'buddypress' ),
1005
  'type' => 'boolean',
1006
  ),
1007
  'parent_id' => array(
237
  if ( empty( $group->id ) ) {
238
  $retval = new WP_Error(
239
  'bp_rest_group_invalid_id',
240
+ __( 'Invalid group ID.', 'buddypress' ),
241
  array(
242
  'status' => 404,
243
  )
441
  if ( true === $retval && empty( $group->id ) ) {
442
  $retval = new WP_Error(
443
  'bp_rest_group_invalid_id',
444
+ __( 'Invalid group ID.', 'buddypress' ),
445
  array(
446
  'status' => 404,
447
  )
545
  if ( true === $retval && empty( $group->id ) ) {
546
  $retval = new WP_Error(
547
  'bp_rest_group_invalid_id',
548
+ __( 'Invalid group ID.', 'buddypress' ),
549
  array(
550
  'status' => 404,
551
  )
1001
  ),
1002
  'enable_forum' => array(
1003
  'context' => array( 'view', 'edit' ),
1004
+ 'description' => __( 'Whether the Group has a forum enabled or not.', 'buddypress' ),
1005
  'type' => 'boolean',
1006
  ),
1007
  'parent_id' => array(
bp-loader.php CHANGED
@@ -15,7 +15,7 @@
15
  * Description: BuddyPress adds community features to WordPress. Member Profiles, Activity Streams, Direct Messaging, Notifications, and more!
16
  * Author: The BuddyPress Community
17
  * Author URI: https://buddypress.org/
18
- * Version: 5.0.0-beta1
19
  * Text Domain: buddypress
20
  * Domain Path: /bp-languages/
21
  * License: GPLv2 or later (license.txt)
15
  * Description: BuddyPress adds community features to WordPress. Member Profiles, Activity Streams, Direct Messaging, Notifications, and more!
16
  * Author: The BuddyPress Community
17
  * Author URI: https://buddypress.org/
18
+ * Version: 5.0.0-beta2
19
  * Text Domain: buddypress
20
  * Domain Path: /bp-languages/
21
  * License: GPLv2 or later (license.txt)
bp-members/classes/class-bp-rest-members-endpoint.php CHANGED
@@ -140,7 +140,7 @@ class BP_REST_Members_Endpoint extends WP_REST_Users_Controller {
140
  if ( ! is_user_logged_in() ) {
141
  $retval = new WP_Error(
142
  'bp_rest_authorization_required',
143
- __( 'Sorry, you are not allowed to view members', 'buddypress' ),
144
  array(
145
  'status' => rest_authorization_required_code(),
146
  )
@@ -152,7 +152,7 @@ class BP_REST_Members_Endpoint extends WP_REST_Users_Controller {
152
  if ( true === $retval && ! $user instanceof WP_User ) {
153
  $retval = new WP_Error(
154
  'bp_rest_member_invalid_id',
155
- __( 'Invalid member id.', 'buddypress' ),
156
  array(
157
  'status' => 404,
158
  )
@@ -229,7 +229,7 @@ class BP_REST_Members_Endpoint extends WP_REST_Users_Controller {
229
  if ( ! $user instanceof WP_User ) {
230
  $retval = new WP_Error(
231
  'bp_rest_member_invalid_id',
232
- __( 'Invalid member id.', 'buddypress' ),
233
  array(
234
  'status' => 404,
235
  )
@@ -597,7 +597,7 @@ class BP_REST_Members_Endpoint extends WP_REST_Users_Controller {
597
  'type' => 'object',
598
  'properties' => array(
599
  'id' => array(
600
- 'description' => __( 'Unique identifier for the member.', 'buddypress' ),
601
  'type' => 'integer',
602
  'context' => array( 'embed', 'view', 'edit' ),
603
  'readonly' => true,
@@ -626,7 +626,7 @@ class BP_REST_Members_Endpoint extends WP_REST_Users_Controller {
626
  'readonly' => true,
627
  ),
628
  'user_login' => array(
629
- 'description' => __( 'An alphanumeric identifier for the member.', 'buddypress' ),
630
  'type' => 'string',
631
  'context' => array( 'embed', 'view', 'edit' ),
632
  'required' => true,
@@ -767,7 +767,7 @@ class BP_REST_Members_Endpoint extends WP_REST_Users_Controller {
767
  );
768
 
769
  $params['include'] = array(
770
- 'description' => __( 'Ensure result set include specific IDs.', 'buddypress' ),
771
  'default' => array(),
772
  'type' => 'array',
773
  'items' => array( 'type' => 'integer' ),
140
  if ( ! is_user_logged_in() ) {
141
  $retval = new WP_Error(
142
  'bp_rest_authorization_required',
143
+ __( 'Sorry, you are not allowed to view members.', 'buddypress' ),
144
  array(
145
  'status' => rest_authorization_required_code(),
146
  )
152
  if ( true === $retval && ! $user instanceof WP_User ) {
153
  $retval = new WP_Error(
154
  'bp_rest_member_invalid_id',
155
+ __( 'Invalid member ID.', 'buddypress' ),
156
  array(
157
  'status' => 404,
158
  )
229
  if ( ! $user instanceof WP_User ) {
230
  $retval = new WP_Error(
231
  'bp_rest_member_invalid_id',
232
+ __( 'Invalid member ID.', 'buddypress' ),
233
  array(
234
  'status' => 404,
235
  )
597
  'type' => 'object',
598
  'properties' => array(
599
  'id' => array(
600
+ 'description' => __( 'A unique numeric ID for the Member.', 'buddypress' ),
601
  'type' => 'integer',
602
  'context' => array( 'embed', 'view', 'edit' ),
603
  'readonly' => true,
626
  'readonly' => true,
627
  ),
628
  'user_login' => array(
629
+ 'description' => __( 'An alphanumeric identifier for the Member.', 'buddypress' ),
630
  'type' => 'string',
631
  'context' => array( 'embed', 'view', 'edit' ),
632
  'required' => true,
767
  );
768
 
769
  $params['include'] = array(
770
+ 'description' => __( 'Ensure result set includes specific IDs.', 'buddypress' ),
771
  'default' => array(),
772
  'type' => 'array',
773
  'items' => array( 'type' => 'integer' ),
bp-messages/classes/class-bp-rest-messages-endpoint.php CHANGED
@@ -197,7 +197,7 @@ class BP_REST_Messages_Endpoint extends WP_REST_Controller {
197
  if ( true === $retval && ! $user instanceof WP_User ) {
198
  $retval = new WP_Error(
199
  'bp_rest_invalid_id',
200
- __( 'Invalid member id.', 'buddypress' ),
201
  array(
202
  'status' => 404,
203
  )
@@ -1208,7 +1208,7 @@ class BP_REST_Messages_Endpoint extends WP_REST_Controller {
1208
  ),
1209
  'starred_message_ids' => array(
1210
  'context' => array( 'view', 'edit' ),
1211
- 'description' => __( 'List of starred message ids.', 'buddypress' ),
1212
  'readonly' => true,
1213
  'type' => 'array',
1214
  'items' => array(
197
  if ( true === $retval && ! $user instanceof WP_User ) {
198
  $retval = new WP_Error(
199
  'bp_rest_invalid_id',
200
+ __( 'Invalid member ID.', 'buddypress' ),
201
  array(
202
  'status' => 404,
203
  )
1208
  ),
1209
  'starred_message_ids' => array(
1210
  'context' => array( 'view', 'edit' ),
1211
+ 'description' => __( 'List of starred message IDs.', 'buddypress' ),
1212
  'readonly' => true,
1213
  'type' => 'array',
1214
  'items' => array(
bp-notifications/classes/class-bp-rest-notifications-endpoint.php CHANGED
@@ -57,7 +57,7 @@ class BP_REST_Notifications_Endpoint extends WP_REST_Controller {
57
  array(
58
  'args' => array(
59
  'id' => array(
60
- 'description' => __( 'The unique numeric ID for the notification.', 'buddypress' ),
61
  'type' => 'integer',
62
  ),
63
  ),
@@ -246,7 +246,7 @@ class BP_REST_Notifications_Endpoint extends WP_REST_Controller {
246
  if ( true === $retval && is_null( $notification->item_id ) ) {
247
  $retval = new WP_Error(
248
  'bp_rest_notification_invalid_id',
249
- __( 'Invalid notification id.', 'buddypress' ),
250
  array(
251
  'status' => 404,
252
  )
@@ -461,7 +461,7 @@ class BP_REST_Notifications_Endpoint extends WP_REST_Controller {
461
  if ( ! BP_Notifications_Notification::delete( array( 'id' => $notification->id ) ) ) {
462
  return new WP_Error(
463
  'bp_rest_notification_invalid_id',
464
- __( 'Invalid notification id.', 'buddypress' ),
465
  array(
466
  'status' => 500,
467
  )
57
  array(
58
  'args' => array(
59
  'id' => array(
60
+ 'description' => __( 'A unique numeric ID for the notification.', 'buddypress' ),
61
  'type' => 'integer',
62
  ),
63
  ),
246
  if ( true === $retval && is_null( $notification->item_id ) ) {
247
  $retval = new WP_Error(
248
  'bp_rest_notification_invalid_id',
249
+ __( 'Invalid notification ID.', 'buddypress' ),
250
  array(
251
  'status' => 404,
252
  )
461
  if ( ! BP_Notifications_Notification::delete( array( 'id' => $notification->id ) ) ) {
462
  return new WP_Error(
463
  'bp_rest_notification_invalid_id',
464
+ __( 'Invalid notification ID.', 'buddypress' ),
465
  array(
466
  'status' => 500,
467
  )
bp-xprofile/classes/class-bp-rest-xprofile-data-endpoint.php CHANGED
@@ -141,7 +141,7 @@ class BP_REST_XProfile_Data_Endpoint extends WP_REST_Controller {
141
  if ( empty( $field->id ) ) {
142
  $retval = new WP_Error(
143
  'bp_rest_invalid_id',
144
- __( 'Invalid field id.', 'buddypress' ),
145
  array(
146
  'status' => 404,
147
  )
@@ -152,7 +152,7 @@ class BP_REST_XProfile_Data_Endpoint extends WP_REST_Controller {
152
  if ( true === $retval && ! bp_rest_get_user( $request['user_id'] ) ) {
153
  $retval = new WP_Error(
154
  'bp_rest_member_invalid_id',
155
- __( 'Invalid member id.', 'buddypress' ),
156
  array(
157
  'status' => 404,
158
  )
@@ -200,7 +200,7 @@ class BP_REST_XProfile_Data_Endpoint extends WP_REST_Controller {
200
  if ( empty( $field->id ) ) {
201
  return new WP_Error(
202
  'bp_rest_invalid_id',
203
- __( 'Invalid field id.', 'buddypress' ),
204
  array(
205
  'status' => 404,
206
  )
@@ -288,7 +288,7 @@ class BP_REST_XProfile_Data_Endpoint extends WP_REST_Controller {
288
  if ( true === $retval && ! $user instanceof WP_User ) {
289
  $retval = new WP_Error(
290
  'bp_rest_invalid_id',
291
- __( 'Invalid member id.', 'buddypress' ),
292
  array(
293
  'status' => 404,
294
  )
@@ -333,7 +333,7 @@ class BP_REST_XProfile_Data_Endpoint extends WP_REST_Controller {
333
  if ( empty( $field->id ) ) {
334
  return new WP_Error(
335
  'bp_rest_invalid_id',
336
- __( 'Invalid field id.', 'buddypress' ),
337
  array(
338
  'status' => 404,
339
  )
@@ -572,7 +572,7 @@ class BP_REST_XProfile_Data_Endpoint extends WP_REST_Controller {
572
  'readonly' => true,
573
  ),
574
  'rendered' => array(
575
- 'description' => __( 'HTML value for the field, transformed for display.' ),
576
  'type' => 'string',
577
  'context' => array( 'view', 'edit' ),
578
  'readonly' => true,
141
  if ( empty( $field->id ) ) {
142
  $retval = new WP_Error(
143
  'bp_rest_invalid_id',
144
+ __( 'Invalid field ID.', 'buddypress' ),
145
  array(
146
  'status' => 404,
147
  )
152
  if ( true === $retval && ! bp_rest_get_user( $request['user_id'] ) ) {
153
  $retval = new WP_Error(
154
  'bp_rest_member_invalid_id',
155
+ __( 'Invalid member ID.', 'buddypress' ),
156
  array(
157
  'status' => 404,
158
  )
200
  if ( empty( $field->id ) ) {
201
  return new WP_Error(
202
  'bp_rest_invalid_id',
203
+ __( 'Invalid field ID.', 'buddypress' ),
204
  array(
205
  'status' => 404,
206
  )
288
  if ( true === $retval && ! $user instanceof WP_User ) {
289
  $retval = new WP_Error(
290
  'bp_rest_invalid_id',
291
+ __( 'Invalid member ID.', 'buddypress' ),
292
  array(
293
  'status' => 404,
294
  )
333
  if ( empty( $field->id ) ) {
334
  return new WP_Error(
335
  'bp_rest_invalid_id',
336
+ __( 'Invalid field ID.', 'buddypress' ),
337
  array(
338
  'status' => 404,
339
  )
572
  'readonly' => true,
573
  ),
574
  'rendered' => array(
575
+ 'description' => __( 'HTML value for the field, transformed for display.', 'buddypress' ),
576
  'type' => 'string',
577
  'context' => array( 'view', 'edit' ),
578
  'readonly' => true,
bp-xprofile/classes/class-bp-rest-xprofile-field-groups-endpoint.php CHANGED
@@ -237,7 +237,7 @@ class BP_REST_XProfile_Field_Groups_Endpoint extends WP_REST_Controller {
237
  if ( empty( $field_group->id ) ) {
238
  return new WP_Error(
239
  'bp_rest_invalid_id',
240
- __( 'Invalid field group id.', 'buddypress' ),
241
  array(
242
  'status' => 404,
243
  )
@@ -418,7 +418,7 @@ class BP_REST_XProfile_Field_Groups_Endpoint extends WP_REST_Controller {
418
  if ( empty( $field_group->id ) ) {
419
  return new WP_Error(
420
  'bp_rest_invalid_id',
421
- __( 'Invalid field group id.', 'buddypress' ),
422
  array(
423
  'status' => 404,
424
  )
@@ -520,7 +520,7 @@ class BP_REST_XProfile_Field_Groups_Endpoint extends WP_REST_Controller {
520
  if ( empty( $field_group->id ) ) {
521
  return new WP_Error(
522
  'bp_rest_invalid_id',
523
- __( 'Invalid field group id.', 'buddypress' ),
524
  array(
525
  'status' => 404,
526
  )
237
  if ( empty( $field_group->id ) ) {
238
  return new WP_Error(
239
  'bp_rest_invalid_id',
240
+ __( 'Invalid field group ID.', 'buddypress' ),
241
  array(
242
  'status' => 404,
243
  )
418
  if ( empty( $field_group->id ) ) {
419
  return new WP_Error(
420
  'bp_rest_invalid_id',
421
+ __( 'Invalid field group ID.', 'buddypress' ),
422
  array(
423
  'status' => 404,
424
  )
520
  if ( empty( $field_group->id ) ) {
521
  return new WP_Error(
522
  'bp_rest_invalid_id',
523
+ __( 'Invalid field group ID.', 'buddypress' ),
524
  array(
525
  'status' => 404,
526
  )
bp-xprofile/classes/class-bp-rest-xprofile-fields-endpoint.php CHANGED
@@ -278,7 +278,7 @@ class BP_REST_XProfile_Fields_Endpoint extends WP_REST_Controller {
278
  if ( empty( $profile_field_id ) || empty( $field->id ) ) {
279
  return new WP_Error(
280
  'bp_rest_invalid_id',
281
- __( 'Invalid field id.', 'buddypress' ),
282
  array(
283
  'status' => 404,
284
  )
@@ -528,7 +528,7 @@ class BP_REST_XProfile_Fields_Endpoint extends WP_REST_Controller {
528
  if ( empty( $field->id ) ) {
529
  return new WP_Error(
530
  'bp_rest_invalid_id',
531
- __( 'Invalid profile field id.', 'buddypress' ),
532
  array(
533
  'status' => 404,
534
  )
@@ -707,7 +707,7 @@ class BP_REST_XProfile_Fields_Endpoint extends WP_REST_Controller {
707
  if ( true === $retval && empty( $field->id ) ) {
708
  $retval = new WP_Error(
709
  'bp_rest_invalid_id',
710
- __( 'Invalid field id.', 'buddypress' ),
711
  array(
712
  'status' => 404,
713
  )
@@ -1057,7 +1057,7 @@ class BP_REST_XProfile_Fields_Endpoint extends WP_REST_Controller {
1057
  'readonly' => true,
1058
  ),
1059
  'rendered' => array(
1060
- 'description' => __( 'HTML value for the field, transformed for display.' ),
1061
  'type' => 'string',
1062
  'context' => array( 'view', 'edit' ),
1063
  'readonly' => true,
278
  if ( empty( $profile_field_id ) || empty( $field->id ) ) {
279
  return new WP_Error(
280
  'bp_rest_invalid_id',
281
+ __( 'Invalid field ID.', 'buddypress' ),
282
  array(
283
  'status' => 404,
284
  )
528
  if ( empty( $field->id ) ) {
529
  return new WP_Error(
530
  'bp_rest_invalid_id',
531
+ __( 'Invalid profile field ID.', 'buddypress' ),
532
  array(
533
  'status' => 404,
534
  )
707
  if ( true === $retval && empty( $field->id ) ) {
708
  $retval = new WP_Error(
709
  'bp_rest_invalid_id',
710
+ __( 'Invalid field ID.', 'buddypress' ),
711
  array(
712
  'status' => 404,
713
  )
1057
  'readonly' => true,
1058
  ),
1059
  'rendered' => array(
1060
+ 'description' => __( 'HTML value for the field, transformed for display.', 'buddypress' ),
1061
  'type' => 'string',
1062
  'context' => array( 'view', 'edit' ),
1063
  'readonly' => true,
buddypress.pot CHANGED
@@ -2,9 +2,9 @@
2
  # This file is distributed under the GPLv2 or later (license.txt).
3
  msgid ""
4
  msgstr ""
5
- "Project-Id-Version: BuddyPress 5.0.0-beta1\n"
6
  "Report-Msgid-Bugs-To: https://buddypress.trac.wordpress.org\n"
7
- "POT-Creation-Date: 2019-08-28 21:41:27+00:00\n"
8
  "MIME-Version: 1.0\n"
9
  "Content-Type: text/plain; charset=utf-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
@@ -972,7 +972,7 @@ msgstr ""
972
  #: bp-activity/classes/class-bp-rest-activity-endpoint.php:577
973
  #: bp-activity/classes/class-bp-rest-activity-endpoint.php:690
974
  #: bp-activity/classes/class-bp-rest-activity-endpoint.php:752
975
- msgid "Invalid activity id."
976
  msgstr ""
977
 
978
  #: bp-activity/classes/class-bp-rest-activity-endpoint.php:634
@@ -1088,6 +1088,7 @@ msgid "Ensure result set excludes specific IDs."
1088
  msgstr ""
1089
 
1090
  #: bp-activity/classes/class-bp-rest-activity-endpoint.php:1446
 
1091
  msgid "Ensure result set includes specific IDs."
1092
  msgstr ""
1093
 
@@ -2155,7 +2156,8 @@ msgstr ""
2155
  msgid "Profile Photo"
2156
  msgstr ""
2157
 
2158
- #: bp-core/bp-core-avatars.php:931
 
2159
  msgid "Upload failed! Error was: %s"
2160
  msgstr ""
2161
 
@@ -2930,12 +2932,16 @@ msgstr ""
2930
  msgid "You have posted too many links"
2931
  msgstr ""
2932
 
2933
- #: bp-core/bp-core-rest-api.php:242
 
 
 
 
2934
  #. translators: %1$s and %2$s is replaced with the registered type(s)
2935
- msgid "The member type you provided, %$1s, is not one of %$2s."
2936
  msgstr ""
2937
 
2938
- #: bp-core/bp-core-rest-api.php:291
2939
  #. translators: %1$s and %2$s is replaced with the registered types
2940
  msgid "The group type you provided, %1$s, is not one of %2$s."
2941
  msgstr ""
@@ -3577,14 +3583,14 @@ msgstr ""
3577
  #: bp-groups/classes/class-bp-rest-group-invites-endpoint.php:211
3578
  #: bp-groups/classes/class-bp-rest-group-invites-endpoint.php:461
3579
  #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:324
3580
- #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:489
3581
- #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:623
3582
  #: bp-groups/classes/class-bp-rest-group-membership-request-endpoint.php:207
3583
  #: bp-groups/classes/class-bp-rest-group-membership-request-endpoint.php:449
3584
  #: bp-groups/classes/class-bp-rest-groups-endpoint.php:240
3585
  #: bp-groups/classes/class-bp-rest-groups-endpoint.php:444
3586
  #: bp-groups/classes/class-bp-rest-groups-endpoint.php:548
3587
- msgid "Invalid group id."
3588
  msgstr ""
3589
 
3590
  #: bp-core/classes/class-bp-rest-attachments-group-avatar-endpoint.php:213
@@ -3597,7 +3603,8 @@ msgid "Sorry, group avatar upload is disabled."
3597
  msgstr ""
3598
 
3599
  #: bp-core/classes/class-bp-rest-attachments-group-avatar-endpoint.php:275
3600
- msgid "Sorry, you are unauthorized to perform this action."
 
3601
  msgstr ""
3602
 
3603
  #: bp-core/classes/class-bp-rest-attachments-group-avatar-endpoint.php:308
@@ -3628,6 +3635,7 @@ msgid "The alt attribute for the <img> element."
3628
  msgstr ""
3629
 
3630
  #: bp-core/classes/class-bp-rest-attachments-member-avatar-endpoint.php:70
 
3631
  msgid "A unique numeric ID for the Member."
3632
  msgstr ""
3633
 
@@ -3640,12 +3648,13 @@ msgstr ""
3640
  #: bp-groups/classes/class-bp-rest-group-invites-endpoint.php:233
3641
  #: bp-groups/classes/class-bp-rest-group-invites-endpoint.php:471
3642
  #: bp-groups/classes/class-bp-rest-group-membership-request-endpoint.php:218
 
3643
  #: bp-members/classes/class-bp-rest-members-endpoint.php:155
3644
  #: bp-members/classes/class-bp-rest-members-endpoint.php:232
3645
  #: bp-messages/classes/class-bp-rest-messages-endpoint.php:200
3646
  #: bp-xprofile/classes/class-bp-rest-xprofile-data-endpoint.php:155
3647
  #: bp-xprofile/classes/class-bp-rest-xprofile-data-endpoint.php:291
3648
- msgid "Invalid member id."
3649
  msgstr ""
3650
 
3651
  #: bp-core/classes/class-bp-rest-attachments-member-avatar-endpoint.php:261
@@ -3656,10 +3665,6 @@ msgstr ""
3656
  msgid "Sorry, member avatar upload is disabled."
3657
  msgstr ""
3658
 
3659
- #: bp-core/classes/class-bp-rest-attachments-member-avatar-endpoint.php:281
3660
- msgid "Sorry, you are not authorized to perform this action."
3661
- msgstr ""
3662
-
3663
  #: bp-core/classes/class-bp-rest-attachments-member-avatar-endpoint.php:314
3664
  msgid "Sorry, there are no uploaded avatars for this user on this site."
3665
  msgstr ""
@@ -3748,13 +3753,8 @@ msgid ""
3748
  "results, upload a picture larger than %1$s x %2$s pixels."
3749
  msgstr ""
3750
 
3751
- #: bp-core/classes/trait-attachments.php:176
3752
- #. translators: %$1s is replaced with error message.
3753
- msgid "Upload failed! Error was: %$1s"
3754
- msgstr ""
3755
-
3756
  #: bp-core/classes/trait-attachments.php:252
3757
- #. translators: %$1s is replaced with object type.
3758
  msgid "There was a problem cropping your %s photo."
3759
  msgstr ""
3760
 
@@ -5275,7 +5275,7 @@ msgstr ""
5275
  #: bp-groups/classes/class-bp-rest-group-invites-endpoint.php:331
5276
  #: bp-groups/classes/class-bp-rest-group-invites-endpoint.php:576
5277
  #: bp-groups/classes/class-bp-rest-group-invites-endpoint.php:702
5278
- msgid "Invalid group invitation id."
5279
  msgstr ""
5280
 
5281
  #: bp-groups/classes/class-bp-rest-group-invites-endpoint.php:351
@@ -5393,9 +5393,9 @@ msgid "Sorry, you need to be logged in to join a group."
5393
  msgstr ""
5394
 
5395
  #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:313
5396
- #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:478
5397
- #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:612
5398
- msgid "Invalid group member id."
5399
  msgstr ""
5400
 
5401
  #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:393
@@ -5406,82 +5406,100 @@ msgstr ""
5406
  msgid "Could not demote member."
5407
  msgstr ""
5408
 
5409
- #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:415
5410
- #. translators: %1$s is replaced with the action
5411
- msgid "Could not %s member from the group."
 
 
 
5412
  msgstr ""
5413
 
5414
- #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:466
 
 
 
 
5415
  #: bp-groups/classes/class-bp-rest-group-membership-request-endpoint.php:546
5416
  msgid "Sorry, you need to be logged in to make an update."
5417
  msgstr ""
5418
 
 
 
 
 
5419
  #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:508
5420
- #. translators: %1$s is replaced with the action.
5421
- msgid "Sorry, you are not allowed to %s this group member."
 
 
 
 
 
 
 
5422
  msgstr ""
5423
 
5424
- #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:551
5425
  msgid "Could not remove member from this group."
5426
  msgstr ""
5427
 
5428
- #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:600
5429
- #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:641
5430
- #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:657
5431
  msgid "Sorry, you need to be logged in to view a group membership."
5432
  msgstr ""
5433
 
5434
- #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:776
5435
  msgid "Group role to assign the user to."
5436
  msgstr ""
5437
 
5438
- #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:790
5439
  msgid "A unique numeric ID for the Member to add to the Group."
5440
  msgstr ""
5441
 
5442
- #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:800
5443
  msgid "Action used to update a group member."
5444
  msgstr ""
5445
 
5446
- #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:840
5447
  msgid "`1` if this member is a Group moderator, `0` otherwise."
5448
  msgstr ""
5449
 
5450
- #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:847
5451
  msgid "`1` if this member has been banned from the Group, `0` otherwise."
5452
  msgstr ""
5453
 
5454
- #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:854
5455
  msgid "`1` if this member is a Group administrator, `0` otherwise."
5456
  msgstr ""
5457
 
5458
- #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:861
5459
  msgid "`1` if the membership of this user has been confirmed, `0` otherwise."
5460
  msgstr ""
5461
 
5462
- #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:868
5463
  msgid ""
5464
  "The date of the last time the membership of this user was modified, in the "
5465
  "site's timezone."
5466
  msgstr ""
5467
 
5468
- #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:898
5469
  msgid "Sort the order of results by the status of the group members."
5470
  msgstr ""
5471
 
5472
- #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:907
5473
  msgid "Ensure result set includes specific Group roles."
5474
  msgstr ""
5475
 
5476
- #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:919
5477
  msgid "Ensure result set excludes specific member IDs."
5478
  msgstr ""
5479
 
5480
- #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:928
5481
  msgid "Whether results should exclude group admins and mods."
5482
  msgstr ""
5483
 
5484
- #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:936
5485
  msgid "Whether results should exclude banned group members."
5486
  msgstr ""
5487
 
@@ -5504,7 +5522,7 @@ msgstr ""
5504
  #: bp-groups/classes/class-bp-rest-group-membership-request-endpoint.php:306
5505
  #: bp-groups/classes/class-bp-rest-group-membership-request-endpoint.php:556
5506
  #: bp-groups/classes/class-bp-rest-group-membership-request-endpoint.php:682
5507
- msgid "Invalid group membership request id."
5508
  msgstr ""
5509
 
5510
  #: bp-groups/classes/class-bp-rest-group-membership-request-endpoint.php:319
@@ -5523,10 +5541,6 @@ msgstr ""
5523
  msgid "Sorry, you need to be logged in to create a membership request."
5524
  msgstr ""
5525
 
5526
- #: bp-groups/classes/class-bp-rest-group-membership-request-endpoint.php:438
5527
- msgid "Invalid user id."
5528
- msgstr ""
5529
-
5530
  #: bp-groups/classes/class-bp-rest-group-membership-request-endpoint.php:462
5531
  msgid "User may not extend requests on behalf of another user."
5532
  msgstr ""
@@ -5637,7 +5651,8 @@ msgid "The status of the Group."
5637
  msgstr ""
5638
 
5639
  #: bp-groups/classes/class-bp-rest-groups-endpoint.php:1004
5640
- msgid "Whether the Group has a forum or not."
 
5641
  msgstr ""
5642
 
5643
  #: bp-groups/classes/class-bp-rest-groups-endpoint.php:1009
@@ -5705,10 +5720,6 @@ msgstr ""
5705
  msgid "Limit results set to a certain Group type."
5706
  msgstr ""
5707
 
5708
- #: bp-groups/classes/class-bp-rest-groups-endpoint.php:1194
5709
- msgid "Whether the Group has a forum enabled or not."
5710
- msgstr ""
5711
-
5712
  #: bp-groups/classes/class-bp-rest-groups-endpoint.php:1202
5713
  msgid "Whether results should include hidden Groups."
5714
  msgstr ""
@@ -6466,9 +6477,6 @@ msgid "Account Activated"
6466
  msgstr ""
6467
 
6468
  #: bp-members/classes/class-bp-rest-members-endpoint.php:143
6469
- msgid "Sorry, you are not allowed to view members"
6470
- msgstr ""
6471
-
6472
  #: bp-members/classes/class-bp-rest-members-endpoint.php:167
6473
  #: bp-members/classes/class-bp-rest-members-endpoint.php:199
6474
  #: bp-members/classes/class-bp-rest-members-endpoint.php:247
@@ -6497,10 +6505,6 @@ msgstr ""
6497
  msgid "The email address for the member."
6498
  msgstr ""
6499
 
6500
- #: bp-members/classes/class-bp-rest-members-endpoint.php:600
6501
- msgid "Unique identifier for the member."
6502
- msgstr ""
6503
-
6504
  #: bp-members/classes/class-bp-rest-members-endpoint.php:606
6505
  msgid "Display name for the member."
6506
  msgstr ""
@@ -6514,7 +6518,7 @@ msgid "Profile URL of the member."
6514
  msgstr ""
6515
 
6516
  #: bp-members/classes/class-bp-rest-members-endpoint.php:629
6517
- msgid "An alphanumeric identifier for the member."
6518
  msgstr ""
6519
 
6520
  #: bp-members/classes/class-bp-rest-members-endpoint.php:638
@@ -6557,10 +6561,6 @@ msgstr ""
6557
  msgid "Pass IDs of users to limit result set."
6558
  msgstr ""
6559
 
6560
- #: bp-members/classes/class-bp-rest-members-endpoint.php:770
6561
- msgid "Ensure result set include specific IDs."
6562
- msgstr ""
6563
-
6564
  #: bp-members/classes/class-bp-rest-members-endpoint.php:788
6565
  msgid "Limit results set to certain type(s)."
6566
  msgstr ""
@@ -7188,7 +7188,7 @@ msgid "List of message objects for the thread."
7188
  msgstr ""
7189
 
7190
  #: bp-messages/classes/class-bp-rest-messages-endpoint.php:1211
7191
- msgid "List of starred message ids."
7192
  msgstr ""
7193
 
7194
  #: bp-messages/classes/class-bp-rest-messages-endpoint.php:1249
@@ -7304,7 +7304,8 @@ msgid "Search Notifications..."
7304
  msgstr ""
7305
 
7306
  #: bp-notifications/classes/class-bp-rest-notifications-endpoint.php:60
7307
- msgid "The unique numeric ID for the notification."
 
7308
  msgstr ""
7309
 
7310
  #: bp-notifications/classes/class-bp-rest-notifications-endpoint.php:172
@@ -7317,7 +7318,7 @@ msgstr ""
7317
 
7318
  #: bp-notifications/classes/class-bp-rest-notifications-endpoint.php:249
7319
  #: bp-notifications/classes/class-bp-rest-notifications-endpoint.php:464
7320
- msgid "Invalid notification id."
7321
  msgstr ""
7322
 
7323
  #: bp-notifications/classes/class-bp-rest-notifications-endpoint.php:259
@@ -7336,10 +7337,6 @@ msgstr ""
7336
  msgid "Cannot update the status of this notification."
7337
  msgstr ""
7338
 
7339
- #: bp-notifications/classes/class-bp-rest-notifications-endpoint.php:757
7340
- msgid "A unique numeric ID for the notification."
7341
- msgstr ""
7342
-
7343
  #: bp-notifications/classes/class-bp-rest-notifications-endpoint.php:763
7344
  msgid "The ID of the user the notification is addressed to."
7345
  msgstr ""
@@ -10307,7 +10304,7 @@ msgstr ""
10307
  #: bp-xprofile/classes/class-bp-rest-xprofile-data-endpoint.php:336
10308
  #: bp-xprofile/classes/class-bp-rest-xprofile-fields-endpoint.php:281
10309
  #: bp-xprofile/classes/class-bp-rest-xprofile-fields-endpoint.php:710
10310
- msgid "Invalid field id."
10311
  msgstr ""
10312
 
10313
  #: bp-xprofile/classes/class-bp-rest-xprofile-data-endpoint.php:168
@@ -10369,7 +10366,7 @@ msgstr ""
10369
  #: bp-xprofile/classes/class-bp-rest-xprofile-field-groups-endpoint.php:240
10370
  #: bp-xprofile/classes/class-bp-rest-xprofile-field-groups-endpoint.php:421
10371
  #: bp-xprofile/classes/class-bp-rest-xprofile-field-groups-endpoint.php:523
10372
- msgid "Invalid field group id."
10373
  msgstr ""
10374
 
10375
  #: bp-xprofile/classes/class-bp-rest-xprofile-field-groups-endpoint.php:322
@@ -10515,7 +10512,7 @@ msgid "Sorry, you are not allowed to create a XProfile field."
10515
  msgstr ""
10516
 
10517
  #: bp-xprofile/classes/class-bp-rest-xprofile-fields-endpoint.php:531
10518
- msgid "Invalid profile field id."
10519
  msgstr ""
10520
 
10521
  #: bp-xprofile/classes/class-bp-rest-xprofile-fields-endpoint.php:572
2
  # This file is distributed under the GPLv2 or later (license.txt).
3
  msgid ""
4
  msgstr ""
5
+ "Project-Id-Version: BuddyPress 5.0.0-beta2\n"
6
  "Report-Msgid-Bugs-To: https://buddypress.trac.wordpress.org\n"
7
+ "POT-Creation-Date: 2019-09-10 16:53:11+00:00\n"
8
  "MIME-Version: 1.0\n"
9
  "Content-Type: text/plain; charset=utf-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
972
  #: bp-activity/classes/class-bp-rest-activity-endpoint.php:577
973
  #: bp-activity/classes/class-bp-rest-activity-endpoint.php:690
974
  #: bp-activity/classes/class-bp-rest-activity-endpoint.php:752
975
+ msgid "Invalid activity ID."
976
  msgstr ""
977
 
978
  #: bp-activity/classes/class-bp-rest-activity-endpoint.php:634
1088
  msgstr ""
1089
 
1090
  #: bp-activity/classes/class-bp-rest-activity-endpoint.php:1446
1091
+ #: bp-members/classes/class-bp-rest-members-endpoint.php:770
1092
  msgid "Ensure result set includes specific IDs."
1093
  msgstr ""
1094
 
2156
  msgid "Profile Photo"
2157
  msgstr ""
2158
 
2159
+ #: bp-core/bp-core-avatars.php:931 bp-core/classes/trait-attachments.php:176
2160
+ #. translators: %s is replaced with error message.
2161
  msgid "Upload failed! Error was: %s"
2162
  msgstr ""
2163
 
2932
  msgid "You have posted too many links"
2933
  msgstr ""
2934
 
2935
+ #: bp-core/bp-core-rest-api.php:93
2936
+ msgid "An unexpected error occured. Please try again."
2937
+ msgstr ""
2938
+
2939
+ #: bp-core/bp-core-rest-api.php:244
2940
  #. translators: %1$s and %2$s is replaced with the registered type(s)
2941
+ msgid "The member type you provided, %1$s, is not one of %2$s."
2942
  msgstr ""
2943
 
2944
+ #: bp-core/bp-core-rest-api.php:293
2945
  #. translators: %1$s and %2$s is replaced with the registered types
2946
  msgid "The group type you provided, %1$s, is not one of %2$s."
2947
  msgstr ""
3583
  #: bp-groups/classes/class-bp-rest-group-invites-endpoint.php:211
3584
  #: bp-groups/classes/class-bp-rest-group-invites-endpoint.php:461
3585
  #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:324
3586
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:491
3587
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:628
3588
  #: bp-groups/classes/class-bp-rest-group-membership-request-endpoint.php:207
3589
  #: bp-groups/classes/class-bp-rest-group-membership-request-endpoint.php:449
3590
  #: bp-groups/classes/class-bp-rest-groups-endpoint.php:240
3591
  #: bp-groups/classes/class-bp-rest-groups-endpoint.php:444
3592
  #: bp-groups/classes/class-bp-rest-groups-endpoint.php:548
3593
+ msgid "Invalid group ID."
3594
  msgstr ""
3595
 
3596
  #: bp-core/classes/class-bp-rest-attachments-group-avatar-endpoint.php:213
3603
  msgstr ""
3604
 
3605
  #: bp-core/classes/class-bp-rest-attachments-group-avatar-endpoint.php:275
3606
+ #: bp-core/classes/class-bp-rest-attachments-member-avatar-endpoint.php:281
3607
+ msgid "Sorry, you are not authorized to perform this action."
3608
  msgstr ""
3609
 
3610
  #: bp-core/classes/class-bp-rest-attachments-group-avatar-endpoint.php:308
3635
  msgstr ""
3636
 
3637
  #: bp-core/classes/class-bp-rest-attachments-member-avatar-endpoint.php:70
3638
+ #: bp-members/classes/class-bp-rest-members-endpoint.php:600
3639
  msgid "A unique numeric ID for the Member."
3640
  msgstr ""
3641
 
3648
  #: bp-groups/classes/class-bp-rest-group-invites-endpoint.php:233
3649
  #: bp-groups/classes/class-bp-rest-group-invites-endpoint.php:471
3650
  #: bp-groups/classes/class-bp-rest-group-membership-request-endpoint.php:218
3651
+ #: bp-groups/classes/class-bp-rest-group-membership-request-endpoint.php:438
3652
  #: bp-members/classes/class-bp-rest-members-endpoint.php:155
3653
  #: bp-members/classes/class-bp-rest-members-endpoint.php:232
3654
  #: bp-messages/classes/class-bp-rest-messages-endpoint.php:200
3655
  #: bp-xprofile/classes/class-bp-rest-xprofile-data-endpoint.php:155
3656
  #: bp-xprofile/classes/class-bp-rest-xprofile-data-endpoint.php:291
3657
+ msgid "Invalid member ID."
3658
  msgstr ""
3659
 
3660
  #: bp-core/classes/class-bp-rest-attachments-member-avatar-endpoint.php:261
3665
  msgid "Sorry, member avatar upload is disabled."
3666
  msgstr ""
3667
 
 
 
 
 
3668
  #: bp-core/classes/class-bp-rest-attachments-member-avatar-endpoint.php:314
3669
  msgid "Sorry, there are no uploaded avatars for this user on this site."
3670
  msgstr ""
3753
  "results, upload a picture larger than %1$s x %2$s pixels."
3754
  msgstr ""
3755
 
 
 
 
 
 
3756
  #: bp-core/classes/trait-attachments.php:252
3757
+ #. translators: %s is replaced with object type.
3758
  msgid "There was a problem cropping your %s photo."
3759
  msgstr ""
3760
 
5275
  #: bp-groups/classes/class-bp-rest-group-invites-endpoint.php:331
5276
  #: bp-groups/classes/class-bp-rest-group-invites-endpoint.php:576
5277
  #: bp-groups/classes/class-bp-rest-group-invites-endpoint.php:702
5278
+ msgid "Invalid group invitation ID."
5279
  msgstr ""
5280
 
5281
  #: bp-groups/classes/class-bp-rest-group-invites-endpoint.php:351
5393
  msgstr ""
5394
 
5395
  #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:313
5396
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:480
5397
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:617
5398
+ msgid "Invalid group member ID."
5399
  msgstr ""
5400
 
5401
  #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:393
5406
  msgid "Could not demote member."
5407
  msgstr ""
5408
 
5409
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:412
5410
+ msgid "Could not demote member from the group."
5411
+ msgstr ""
5412
+
5413
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:413
5414
+ msgid "Could not ban member from the group."
5415
  msgstr ""
5416
 
5417
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:414
5418
+ msgid "Could not unban member from the group."
5419
+ msgstr ""
5420
+
5421
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:468
5422
  #: bp-groups/classes/class-bp-rest-group-membership-request-endpoint.php:546
5423
  msgid "Sorry, you need to be logged in to make an update."
5424
  msgstr ""
5425
 
5426
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:507
5427
+ msgid "Sorry, you are not allowed to ban this group member."
5428
+ msgstr ""
5429
+
5430
  #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:508
5431
+ msgid "Sorry, you are not allowed to unban this group member."
5432
+ msgstr ""
5433
+
5434
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:509
5435
+ msgid "Sorry, you are not allowed to promote this group member."
5436
+ msgstr ""
5437
+
5438
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:510
5439
+ msgid "Sorry, you are not allowed to demote this group member."
5440
  msgstr ""
5441
 
5442
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:556
5443
  msgid "Could not remove member from this group."
5444
  msgstr ""
5445
 
5446
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:605
5447
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:646
5448
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:662
5449
  msgid "Sorry, you need to be logged in to view a group membership."
5450
  msgstr ""
5451
 
5452
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:781
5453
  msgid "Group role to assign the user to."
5454
  msgstr ""
5455
 
5456
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:795
5457
  msgid "A unique numeric ID for the Member to add to the Group."
5458
  msgstr ""
5459
 
5460
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:805
5461
  msgid "Action used to update a group member."
5462
  msgstr ""
5463
 
5464
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:845
5465
  msgid "`1` if this member is a Group moderator, `0` otherwise."
5466
  msgstr ""
5467
 
5468
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:852
5469
  msgid "`1` if this member has been banned from the Group, `0` otherwise."
5470
  msgstr ""
5471
 
5472
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:859
5473
  msgid "`1` if this member is a Group administrator, `0` otherwise."
5474
  msgstr ""
5475
 
5476
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:866
5477
  msgid "`1` if the membership of this user has been confirmed, `0` otherwise."
5478
  msgstr ""
5479
 
5480
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:873
5481
  msgid ""
5482
  "The date of the last time the membership of this user was modified, in the "
5483
  "site's timezone."
5484
  msgstr ""
5485
 
5486
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:903
5487
  msgid "Sort the order of results by the status of the group members."
5488
  msgstr ""
5489
 
5490
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:912
5491
  msgid "Ensure result set includes specific Group roles."
5492
  msgstr ""
5493
 
5494
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:924
5495
  msgid "Ensure result set excludes specific member IDs."
5496
  msgstr ""
5497
 
5498
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:933
5499
  msgid "Whether results should exclude group admins and mods."
5500
  msgstr ""
5501
 
5502
+ #: bp-groups/classes/class-bp-rest-group-membership-endpoint.php:941
5503
  msgid "Whether results should exclude banned group members."
5504
  msgstr ""
5505
 
5522
  #: bp-groups/classes/class-bp-rest-group-membership-request-endpoint.php:306
5523
  #: bp-groups/classes/class-bp-rest-group-membership-request-endpoint.php:556
5524
  #: bp-groups/classes/class-bp-rest-group-membership-request-endpoint.php:682
5525
+ msgid "Invalid group membership request ID."
5526
  msgstr ""
5527
 
5528
  #: bp-groups/classes/class-bp-rest-group-membership-request-endpoint.php:319
5541
  msgid "Sorry, you need to be logged in to create a membership request."
5542
  msgstr ""
5543
 
 
 
 
 
5544
  #: bp-groups/classes/class-bp-rest-group-membership-request-endpoint.php:462
5545
  msgid "User may not extend requests on behalf of another user."
5546
  msgstr ""
5651
  msgstr ""
5652
 
5653
  #: bp-groups/classes/class-bp-rest-groups-endpoint.php:1004
5654
+ #: bp-groups/classes/class-bp-rest-groups-endpoint.php:1194
5655
+ msgid "Whether the Group has a forum enabled or not."
5656
  msgstr ""
5657
 
5658
  #: bp-groups/classes/class-bp-rest-groups-endpoint.php:1009
5720
  msgid "Limit results set to a certain Group type."
5721
  msgstr ""
5722
 
 
 
 
 
5723
  #: bp-groups/classes/class-bp-rest-groups-endpoint.php:1202
5724
  msgid "Whether results should include hidden Groups."
5725
  msgstr ""
6477
  msgstr ""
6478
 
6479
  #: bp-members/classes/class-bp-rest-members-endpoint.php:143
 
 
 
6480
  #: bp-members/classes/class-bp-rest-members-endpoint.php:167
6481
  #: bp-members/classes/class-bp-rest-members-endpoint.php:199
6482
  #: bp-members/classes/class-bp-rest-members-endpoint.php:247
6505
  msgid "The email address for the member."
6506
  msgstr ""
6507
 
 
 
 
 
6508
  #: bp-members/classes/class-bp-rest-members-endpoint.php:606
6509
  msgid "Display name for the member."
6510
  msgstr ""
6518
  msgstr ""
6519
 
6520
  #: bp-members/classes/class-bp-rest-members-endpoint.php:629
6521
+ msgid "An alphanumeric identifier for the Member."
6522
  msgstr ""
6523
 
6524
  #: bp-members/classes/class-bp-rest-members-endpoint.php:638
6561
  msgid "Pass IDs of users to limit result set."
6562
  msgstr ""
6563
 
 
 
 
 
6564
  #: bp-members/classes/class-bp-rest-members-endpoint.php:788
6565
  msgid "Limit results set to certain type(s)."
6566
  msgstr ""
7188
  msgstr ""
7189
 
7190
  #: bp-messages/classes/class-bp-rest-messages-endpoint.php:1211
7191
+ msgid "List of starred message IDs."
7192
  msgstr ""
7193
 
7194
  #: bp-messages/classes/class-bp-rest-messages-endpoint.php:1249
7304
  msgstr ""
7305
 
7306
  #: bp-notifications/classes/class-bp-rest-notifications-endpoint.php:60
7307
+ #: bp-notifications/classes/class-bp-rest-notifications-endpoint.php:757
7308
+ msgid "A unique numeric ID for the notification."
7309
  msgstr ""
7310
 
7311
  #: bp-notifications/classes/class-bp-rest-notifications-endpoint.php:172
7318
 
7319
  #: bp-notifications/classes/class-bp-rest-notifications-endpoint.php:249
7320
  #: bp-notifications/classes/class-bp-rest-notifications-endpoint.php:464
7321
+ msgid "Invalid notification ID."
7322
  msgstr ""
7323
 
7324
  #: bp-notifications/classes/class-bp-rest-notifications-endpoint.php:259
7337
  msgid "Cannot update the status of this notification."
7338
  msgstr ""
7339
 
 
 
 
 
7340
  #: bp-notifications/classes/class-bp-rest-notifications-endpoint.php:763
7341
  msgid "The ID of the user the notification is addressed to."
7342
  msgstr ""
10304
  #: bp-xprofile/classes/class-bp-rest-xprofile-data-endpoint.php:336
10305
  #: bp-xprofile/classes/class-bp-rest-xprofile-fields-endpoint.php:281
10306
  #: bp-xprofile/classes/class-bp-rest-xprofile-fields-endpoint.php:710
10307
+ msgid "Invalid field ID."
10308
  msgstr ""
10309
 
10310
  #: bp-xprofile/classes/class-bp-rest-xprofile-data-endpoint.php:168
10366
  #: bp-xprofile/classes/class-bp-rest-xprofile-field-groups-endpoint.php:240
10367
  #: bp-xprofile/classes/class-bp-rest-xprofile-field-groups-endpoint.php:421
10368
  #: bp-xprofile/classes/class-bp-rest-xprofile-field-groups-endpoint.php:523
10369
+ msgid "Invalid field group ID."
10370
  msgstr ""
10371
 
10372
  #: bp-xprofile/classes/class-bp-rest-xprofile-field-groups-endpoint.php:322
10512
  msgstr ""
10513
 
10514
  #: bp-xprofile/classes/class-bp-rest-xprofile-fields-endpoint.php:531
10515
+ msgid "Invalid profile field ID."
10516
  msgstr ""
10517
 
10518
  #: bp-xprofile/classes/class-bp-rest-xprofile-fields-endpoint.php:572
class-buddypress.php CHANGED
@@ -303,7 +303,7 @@ class BuddyPress {
303
 
304
  /** Versions **********************************************************/
305
 
306
- $this->version = '5.0.0-beta1';
307
  $this->db_version = 12385;
308
 
309
  /** Loading ***********************************************************/
303
 
304
  /** Versions **********************************************************/
305
 
306
+ $this->version = '5.0.0-beta2';
307
  $this->db_version = 12385;
308
 
309
  /** Loading ***********************************************************/