src/Database/Scope/Scope.php
public function applyToRelationQuery($query, $table)
    {
        if (is_null($this->scope)) {
            return $query;
        }

        return $this->applyToQuery($query, $table);
    }
public function applyToRelationQuery($query, $table)
    {
        if (is_null($this->scope)) {
            return $query;
        }

        return $this->applyToQuery($query, $table);
    }
public function applyToRelationQuery ( $ query , $ table ) { if ( is_null ( $ this -> scope ) ) { return $ query ; } return $ this -> applyToQuery ( $ query , $ table ) ; }
Scope the given relationship query to the current tenant.

@param  \Illuminate\Database\Query\Builder|\Illuminate\Database\Eloquent\Builder  $query
@param  string  $table
@return \Illuminate\Database\Query\Builder|\Illuminate\Database\Eloquent\Builder
Scope the given relationship query to the current tenant .