Skip to content

Commit

Permalink
Merge pull request #26 from atarime/remove-unnecessary-function-arg-a…
Browse files Browse the repository at this point in the history
…gain

Remove unnecessary function arg again
  • Loading branch information
kznakata authored Jan 9, 2025
2 parents b15a0b0 + 475794a commit 1c25571
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions includes/class-forms.php
Original file line number Diff line number Diff line change
Expand Up @@ -590,10 +590,9 @@ private function is_fm_field( $tag ) {
* @since 1.0.0
* @access private
* @param object|array $tag CF7 tag.
* @param bool $array true if the arg is an array.
*/
private function get_fm_field( $tag, $array = false ) {
$name = $array ? $tag['name'] : $tag->name;
private function get_fm_field( $tag ) {
$name = is_array( $tag ) ? $tag['name'] : $tag->name;
return isset( $name ) ? mb_substr( $name, mb_strlen( self::FM_FIELD_PREFIX ) ) : null;
}

Expand Down

0 comments on commit 1c25571

Please sign in to comment.