src/ckanext-Metadata/ckanext/Metadata/plugin.py
def before_search(self, search_params):
        '''
            Extensions will receive a dictionary with the query parameters,
            and should return a modified (or not) version of it.

            search_params will include an `extras` dictionary with all values
            from fields starting with `ext_`, so extensions can receive user
            input from specific fields.

        '''
        # when listing datasets outside an organization, get only the
        # public (private:false) datasets
        if not 'owner_org' in search_params['q']:
            if len(search_params['q']) > 0:
                search_params['q'] += ' private:false'
            else:
                search_params['q'] = 'private:false'

        return search_params

            Extensions will receive a dictionary with the query parameters,
            and should return a modified (or not) version of it.

            search_params will include an `extras` dictionary with all values
            from fields starting with `ext_`, so extensions can receive user
            input from specific fields.

        
Extensions will receive a dictionary with the query parameters,
and should return a modified (or not) version of it.

search_params will include an `extras` dictionary with all values
from fields starting with `ext_`, so extensions can receive user
input from specific fields.
Extensions will receive a dictionary with the query parameters and should return a modified ( or not ) version of it . search_params will include an ` extras ` dictionary with all values from fields starting with ` ext_ ` so extensions can receive user input from specific fields .
def before_search(self, search_params):
        if not 'owner_org' in search_params['q']:
            if len(search_params['q']) > 0:
                search_params['q'] += ' private:false'
            else:
                search_params['q'] = 'private:false'
        return search_params
def before_search ( self , search_params ) : if not 'owner_org' in search_params [ 'q' ] : if len ( search_params [ 'q' ] ) > 0 : search_params [ 'q' ] += ' private:false' else : search_params [ 'q' ] = 'private:false' return search_params
Extensions will receive a dictionary with the query parameters,
and should return a modified (or not) version of it.
Extensions will receive a dictionary with the query parameters and should return a modified ( or not ) version of it .
'''
            Extensions will receive a dictionary with the query parameters,
            and should return a modified (or not) version of it.

            search_params will include an `extras` dictionary with all values
            from fields starting with `ext_`, so extensions can receive user
            input from specific fields.

        ''' # when listing datasets outside an organization, get only the # public (private:false) datasets
self
search_params