Skip to content

Inefficient code slows down Wayfinder #2

@shamblett

Description

@shamblett

Lines 617 and 618 of the main wayfinder class(wayfinder.class.php) are inefficently getting a chunk twice, from my cachegrind outputs this can seriously affect Wayfinders performance, the lines :-

if ($this->modx->getChunk($tpl) != "") {
$template = $this->modx->getChunk($tpl);

can be easily optimised to get the chunk once, then test it, not twice as above.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions