Skip to content

Component isEnabled() function does not return Model #1

@hairthing

Description

@hairthing

The comments say
* Returns appropriate Model or false on not active
* @return mixed Object or false on failure
But it only returns true or false

I could only get it working after changing

    return ($Model->Behaviors->attached('Searchable') && $Model->elastic_enabled());

to

    return $Model;

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions