Skip to content

Commit

Permalink
Change json_command dictionary and add conditional to add params at s…
Browse files Browse the repository at this point in the history
…end_command()
  • Loading branch information
neyberson committed Aug 8, 2024
1 parent 41bde75 commit f5c87c8
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion devtools/session.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,11 @@ def send_command(self, command, params=None, cb=None):
json_command = {
"id": self.message_id,
"method": command,
"params": params,
}

if params:
json_command["params"] = params

if self.session_id != "":
json_command["session_id"] = self.session_id

Expand Down

0 comments on commit f5c87c8

Please sign in to comment.