Skip to content

Commit

Permalink
Merge pull request #235 from tayler6000/bugfix/registration_issue
Browse files Browse the repository at this point in the history
Fixed issue with registration
  • Loading branch information
tayler6000 authored Jan 27, 2024
2 parents 9b02be6 + b623687 commit 38c6c95
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 8 deletions.
8 changes: 4 additions & 4 deletions pyVoIP/SIP/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -549,9 +549,9 @@ def gen_first_request(self, deregister=False) -> str:
regRequest += self.__gen_from_to(
"From",
self.user,
self.nat.get_host(self.server),
self.server,
method=method,
port=self.bind_port,
port=self.port,
header_parms=f";tag={tag}",
)
regRequest += self.__gen_from_to(
Expand Down Expand Up @@ -631,9 +631,9 @@ def gen_register(self, request: SIPMessage, deregister=False) -> str:
regRequest += self.__gen_from_to(
"From",
self.user,
self.nat.get_host(self.server),
self.server,
method=method,
port=self.bind_port,
port=self.port,
header_parms=f";tag={self.tagLibrary['register']}",
)
regRequest += self.__gen_from_to(
Expand Down
6 changes: 2 additions & 4 deletions pyVoIP/SIP/message.py
Original file line number Diff line number Diff line change
Expand Up @@ -749,10 +749,8 @@ def parse_body(self, header: str, data: str) -> None:
or attribute == "sendonly"
or attribute == "inactive"
):
self.body["a"][
"transmit_type"
] = pyVoIP.RTP.TransmitType(
attribute
self.body["a"]["transmit_type"] = (
pyVoIP.RTP.TransmitType(attribute)
) # noqa: E501
else:
self.body[header] = data
Expand Down
1 change: 1 addition & 0 deletions pyVoIP/regex.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
each search. This module holds all the compiled regex so it can be compiled
once on startup, then used directly later by other modules.
"""

import re


Expand Down

0 comments on commit 38c6c95

Please sign in to comment.