Skip to content

Commit 3a63cb1

Browse files
author
abel
committed
(fix) Made cookie_assistant parameter optional when creating a custom network instance
1 parent f2d9e85 commit 3a63cb1

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

pyinjective/core/network.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -370,8 +370,9 @@ def custom(
370370
grpc_explorer_endpoint,
371371
chain_id,
372372
env,
373-
cookie_assistant: CookieAssistant,
373+
cookie_assistant: Optional[CookieAssistant] = None,
374374
):
375+
assistant = cookie_assistant or DisabledCookieAssistant()
375376
return cls(
376377
lcd_endpoint=lcd_endpoint,
377378
tm_websocket_endpoint=tm_websocket_endpoint,
@@ -381,7 +382,7 @@ def custom(
381382
chain_id=chain_id,
382383
fee_denom="inj",
383384
env=env,
384-
cookie_assistant=cookie_assistant
385+
cookie_assistant=assistant
385386
)
386387

387388
def string(self):

0 commit comments

Comments
 (0)