Skip to content

Loop to fill zone details does not work #92

@GaryJones

Description

@GaryJones

zoninator/zoninator.php

Lines 1219 to 1221 in 5588e05

foreach( $zones as $zone ) {
$zone = $this->_fill_zone_details( $zone );
}

That assignment back to $zone is flawed, since the variable just gets overridden on the next loop iteration, and the original $zones (which is returned from the function) is never updated.

See https://3v4l.org/QMZl6 as a POC.

While the fix is easy, we'll need to see what the implications are for having the $zones now populated with more data.

Metadata

Metadata

Assignees

No one assigned

    Labels

    type: bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions