OSDN Git Service
(root)
/
wvm
/
wvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8bde3c0
)
remove unnecessary temporary variable
author
scribu
<mail@scribu.net>
Thu, 1 Aug 2013 00:49:25 +0000
(
03:49
+0300)
committer
scribu
<mail@scribu.net>
Thu, 1 Aug 2013 00:49:25 +0000
(
03:49
+0300)
php/commands/post.php
patch
|
blob
|
history
php/commands/user.php
patch
|
blob
|
history
diff --git
a/php/commands/post.php
b/php/commands/post.php
index
f368f7b
..
1792830
100644
(file)
--- a/
php/commands/post.php
+++ b/
php/commands/post.php
@@
-97,7
+97,6
@@
class Post_Command extends \WP_CLI\CommandWithDBObject {
$assoc_args = wp_parse_args( $assoc_args, array(
'format' => 'table'
) );
- $format = $assoc_args['format'];
$post_id = $args[0];
if ( !$post_id || !$post = get_post( $post_id ) )
@@
-122,7
+121,7
@@
class Post_Command extends \WP_CLI\CommandWithDBObject {
break;
default:
- \WP_CLI::error( "Invalid
value for format: " . $format
);
+ \WP_CLI::error( "Invalid
format: " . $assoc_args['format']
);
break;
}
diff --git
a/php/commands/user.php
b/php/commands/user.php
index
f80b56c
..
7a874a0
100644
(file)
--- a/
php/commands/user.php
+++ b/
php/commands/user.php
@@
-87,7
+87,7
@@
class User_Command extends \WP_CLI\CommandWithDBObject {
break;
default:
- \WP_CLI::error( "Invalid
value for format: " . $format
);
+ \WP_CLI::error( "Invalid
format: " . $assoc_args['format']
);
break;
}