Skip to content

Commit 6f8da0a

Browse files
committed
Adding client initialization in readme example
1 parent 2474ae1 commit 6f8da0a

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

Diff for: README.md

+2
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,9 @@ By default, the client now overrides the server-side dialect with version 2, aut
164164
>>> from redis.commands.search.field import TextField
165165
>>> from redis.commands.search.query import Query
166166
>>> from redis.commands.search.index_definition import IndexDefinition
167+
>>> import redis
167168

169+
>>> r = redis.Redis(host='localhost', port=6379, db=0)
168170
>>> r.ft().create_index(
169171
>>> (TextField("name"), TextField("lastname")),
170172
>>> definition=IndexDefinition(prefix=["test:"]),

0 commit comments

Comments
 (0)