Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed issue with registration #235

Merged
merged 1 commit into from
Jan 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
Loading