Silber\Bouncer\Conductors\Traits\AssociatesAbilities::getAuthority PHP Method

getAuthority() protected method

Get the authority, creating a role authority if necessary.
protected getAuthority ( ) : Model
return Illuminate\Database\Eloquent\Model
    protected function getAuthority()
    {
        if ($this->authority instanceof Model) {
            return $this->authority;
        }
        return Models::role()->firstOrCreate(['name' => $this->authority]);
    }