Skip to content

Commit ec69a24

Browse files
committed
IndexDefinition: remvoed async parameter from ctor
1 parent dc94637 commit ec69a24

File tree

1 file changed

+10
-14
lines changed

1 file changed

+10
-14
lines changed

redisearch/client.py

+10-14
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,6 @@ class IndexDefinition(object):
104104

105105
ON = 'ON'
106106
HASH = 'HASH'
107-
ASYNC = 'ASYNC'
108107
PREFIX = 'PREFIX'
109108
FILTER = 'FILTER'
110109
LANGUAGE_FIELD = 'LANGUAGE_FIELD'
@@ -113,43 +112,40 @@ class IndexDefinition(object):
113112
SCORE = 'SCORE'
114113
PAYLOAD_FIELD = 'PAYLOAD_FIELD'
115114

116-
def __init__(self, async_=False, prefix=[], filter=None, language_field=None, language=None, score_field=None, score=1.0, payload_field=None):
117-
115+
def __init__(self, prefix=[], filter=None, language_field=None, language=None, score_field=None, score=1.0, payload_field=None):
116+
118117
args = [self.ON, self.HASH]
119-
120-
if async_:
121-
args.append(self.ASYNC)
122-
118+
123119
if len(prefix) > 0:
124120
args.append(self.PREFIX)
125121
args.append(len(prefix))
126122
for p in prefix:
127123
args.append(p)
128-
124+
129125
if filter is not None:
130126
args.append(self.FILTER)
131127
args.append(filter)
132-
128+
133129
if language_field is not None:
134130
args.append(self.LANGUAGE_FIELD)
135131
args.append(language_field)
136-
132+
137133
if language is not None:
138134
args.append(self.LANGUAGE)
139135
args.append(language)
140-
136+
141137
if score_field is not None:
142138
args.append(self.SCORE_FIELD)
143139
args.append(score_field)
144-
140+
145141
if score is not None:
146142
args.append(self.SCORE)
147143
args.append(score)
148-
144+
149145
if payload_field is not None:
150146
args.append(self.PAYLOAD_FIELD)
151147
args.append(payload_field)
152-
148+
153149
self.args = args
154150

155151

0 commit comments

Comments
 (0)