Skip to content

Commit 80cacd2

Browse files
Fix undefined variable
1 parent 1637118 commit 80cacd2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Post_Command.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -896,7 +896,7 @@ public function generate( $args, $assoc_args ) {
896896
public function url_to_id( $args, $assoc_args ) {
897897
$post_id = url_to_postid( $args[0] );
898898

899-
if ( ! $value ) {
899+
if ( ! $post_id ) {
900900
WP_CLI::error( "Could not get post with url '$args[0]'." );
901901
}
902902

0 commit comments

Comments
 (0)