Problem/Motivation

PHP trips an E_STRICT warning ("Only variables should be passed by reference") when running reviews. This is caused by the insertion of a function call into array_splice on line 155 of client.inc:

$this->operations = array_splice($plugin->operation_get_all(), 0, -2);

Proposed resolution

Attached patch gets rid of the warning by moving the operation_get_all() command out of the array_splice function:

$operations = $plugin->operation_get_all();
$this->operations = array_splice($operations, 0, -2);

Remaining tasks

Trivial change ... needs review and commit

Comments

jthorson’s picture

StatusFileSize
new593 bytes

Oh crap ... $operations is a protected variable ... renaming to avoid confusion.

jthorson’s picture

Status: Active » Needs review
rfay’s picture

Status: Needs review » Fixed

Committed: a3901c2

Thanks!

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.