Changeset 12985
- Timestamp:
- 07/02/2021 01:47:57 AM (3 years ago)
- Location:
- trunk/src
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/bp-core/bp-core-rest-api.php
r12745 r12985 136 136 137 137 /** 138 * Get user URL. 139 * 140 * @since 5.0.0 141 * 142 * @param int $user_id User ID. 138 * Get a REST API object URL from a component. 139 * 140 * @since 9.0.0 141 * 142 * @param integer $object_id Object ID. 143 * @param string $object_path Path of the component endpoint. 143 144 * @return string 144 145 */ 145 function bp_rest_get_user_url( $user_id ) { 146 return sprintf( 147 '/%s/%s/members/%d', 148 bp_rest_namespace(), 149 bp_rest_version(), 150 $user_id 146 function bp_rest_get_object_url( $object_id, $object_path ) { 147 return rest_url( 148 sprintf( 149 '/%1$s/%2$s/%3$s/%4$d', 150 bp_rest_namespace(), 151 bp_rest_version(), 152 $object_path, 153 $object_id 154 ) 151 155 ); 152 156 } -
trunk/src/class-buddypress.php
r12974 r12985 513 513 require( $this->plugin_dir . 'bp-core/deprecated/7.0.php' ); 514 514 require( $this->plugin_dir . 'bp-core/deprecated/8.0.php' ); 515 require( $this->plugin_dir . 'bp-core/deprecated/9.0.php' ); 515 516 } 516 517
Note: See TracChangeset
for help on using the changeset viewer.