Skip to content

Commit

Permalink
Fixing a bug and other doc improvements
Browse files Browse the repository at this point in the history
  • Loading branch information
renatonascalves committed Sep 7, 2020
1 parent e447a35 commit e5675cf
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 16 deletions.
3 changes: 3 additions & 0 deletions features/scaffold.feature
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@ Feature: Scaffold BuddyPress tests
And the {PLUGIN_DIR}/hello-world/tests directory should contain:
"""
bootstrap.php
"""
And the {PLUGIN_DIR}/hello-world/tests directory should contain:
"""
bootstrap-buddypress.php
"""
And the {PLUGIN_DIR}/hello-world/tests/bootstrap-buddypress.php file should contain:
Expand Down
11 changes: 0 additions & 11 deletions src/member.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@

namespace Buddypress\CLI\Command;

use WP_CLI;

/**
* Manage BuddyPress Members
*
Expand All @@ -16,15 +14,6 @@
*/
class Member extends BuddyPressCommand {

/**
* Default dependency check for a BuddyPress CLI command.
*/
public static function check_dependencies() {
if ( ! class_exists( 'Buddypress' ) ) {
WP_CLI::error( 'The BuddyPress plugin is not active.' );
}
}

/**
* Generate BuddyPress members. See documentation for `wp_user_generate`.
*
Expand Down
7 changes: 4 additions & 3 deletions src/tool.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@
* $ wp bp tool repair friend-count
* Success: Counting the number of friends for each user. Complete!
*
* $ wp bp tool version
* BuddyPress: 6.0.0
*
* @since 1.5.0
*/
class Tool extends BuddyPressCommand {
Expand Down Expand Up @@ -41,7 +44,7 @@ public static function check_dependencies() {
* - last-activity
* ---
*
* ## EXAMPLES
* ## EXAMPLE
*
* $ wp bp tool repair friend-count
* Success: Counting the number of friends for each user. Complete!
Expand Down Expand Up @@ -94,8 +97,6 @@ public function version() {
*
* $ wp bp tool signup 0
* Success: Signup tool updated.
*
* @since 2.0.0
*/
public function signup( $args ) {
bp_update_option( 'users_can_register', $args[0] );
Expand Down
4 changes: 2 additions & 2 deletions src/xprofile-field.php
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ public function list_( $args, $assoc_args ) { // phpcs:ignore PSR2.Methods.Metho
*
* ## OPTIONS
*
* --type=<type>
* [--type=<type>]
* : Field type.
* ---
* default: textbox
Expand All @@ -88,7 +88,7 @@ public function list_( $args, $assoc_args ) { // phpcs:ignore PSR2.Methods.Metho
* $ wp bp xprofile field create --type=checkbox --field-group-id=508 --name="Field Name"
* Success: Created XProfile field "Field Name" (ID 24564).
*
* $ wp bp xprofile field add --type=checkbox --field-group-id=165 --name="Another Field"
* $ wp bp xprofile field add --field-group-id=165 --name="Another Field"
* Success: Created XProfile field "Another Field" (ID 5465).
*
* @alias add
Expand Down

0 comments on commit e5675cf

Please sign in to comment.