WordPress.org

Plugin Directory

gengo

Opened 9 years ago

Last modified 9 years ago

#936 assigned defect

implode(): Invalid arguments passed in gengo.php on line 1484

Reported by: mark8barnes Owned by: pixline
Priority: normal Severity: normal
Plugin: gengo Keywords: needs-testing
Cc: supporto@…

Description

This line assumes that $ids is always an array, but if you only have one language selected, it is not an array. The solution is to test for the array before calling the function:

if (is_array($ids)) {
	$language_ids = implode(",", $ids);
} else {
        $language_ids = $ids;
}

Change History (2)

comment:1 @pixline9 years ago

  • Cc supporto@… added
  • Owner changed from majelbstoat to pixline
  • Status changed from new to assigned

comment:2 @pixline9 years ago

  • Keywords needs-testing added; bug implode has-patch removed

committed on [91431]

Note: See TracTickets for help on using tickets.