Skip to content

Commit 64e9d34

Browse files
swissspidyclaude
andauthored
Ensure parent term ID is non-negative in Term_Command (#662)
Co-authored-by: Claude <noreply@anthropic.com>
1 parent 884d01c commit 64e9d34

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎src/Term_Command.php‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -590,7 +590,7 @@ public function generate( $args, $assoc_args ) {
590590
}
591591

592592
$args = [
593-
'parent' => $current_parent,
593+
'parent' => max( 0, $current_parent ),
594594
'slug' => $slug . "-{$index}",
595595
];
596596

0 commit comments

Comments
 (0)