(**kwargs)
return query_dict
Build a dictionary from kwargs
Build a dictionary from kwargs
Build a dictionary from kwargs
def build_query_dict(**kwargs):
        """Build a dictionary from kwargs"""
        query_dict = dict()
        if kwargs.get('id'):
            query_dict['id'] = kwargs.get('id')
        if kwargs.get('short_code'):
            query_dict['short_code'] = kwargs.get('short_code')
        if kwargs.get('owner'):
            query_dict['owner'] = kwargs.get('owner')
        if kwargs.get('short_code'):
            query_dict['short_code'] = kwargs.get('short_code')
        if kwargs.get('is_custom') is not None:
            query_dict['is_custom'] = kwargs.get('is_custom')
        if kwargs.get('is_protected') is not None:
            query_dict['is_protected'] = kwargs.get('is_protected')
        # TODO: handle disabled
        return query_dict
def build_query_dict ( * * kwargs ) : query_dict = dict ( ) if kwargs . get ( 'id' ) : query_dict [ 'id' ] = kwargs . get ( 'id' ) if kwargs . get ( 'short_code' ) : query_dict [ 'short_code' ] = kwargs . get ( 'short_code' ) if kwargs . get ( 'owner' ) : query_dict [ 'owner' ] = kwargs . get ( 'owner' ) if kwargs . get ( 'short_code' ) : query_dict [ 'short_code' ] = kwargs . get ( 'short_code' ) if kwargs . get ( 'is_custom' ) is not None : query_dict [ 'is_custom' ] = kwargs . get ( 'is_custom' ) if kwargs . get ( 'is_protected' ) is not None : query_dict [ 'is_protected' ] = kwargs . get ( 'is_protected' ) # TODO: handle disabled return query_dict