Skip to content

Commit 2d483eb

Browse files
committed
refactor: Replace 'private' with 'direct'.
1 parent dc4d9bc commit 2d483eb

File tree

5 files changed

+6
-6
lines changed

5 files changed

+6
-6
lines changed

tests/conftest.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -450,7 +450,7 @@ def msg_template_factory(
450450
"""
451451
Generate message template for all types of messages(stream/PM/group)
452452
"""
453-
# TODO: Separate Message into distinct types for stream and private messages.
453+
# TODO: Separate Message into distinct types for stream and direct messages.
454454
message = Message(
455455
id=msg_id,
456456
sender_full_name="Foo Foo",

tests/ui_tools/test_buttons.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,10 @@
1010
from zulipterminal.config.symbols import CHECK_MARK, MUTE_MARKER
1111
from zulipterminal.ui_tools.buttons import (
1212
DecodedStream,
13+
PMButton,
1314
EmojiButton,
1415
MessageLinkButton,
1516
ParsedNarrowLink,
16-
PMButton,
1717
StarredButton,
1818
StreamButton,
1919
TopButton,

zulipterminal/model.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1555,7 +1555,7 @@ def get_stream_by_id(streams: List[StreamData], stream_id: int) -> StreamData:
15551555

15561556
def _handle_typing_event(self, event: Event) -> None:
15571557
"""
1558-
Handle typing notifications (in private messages)
1558+
Handle typing notifications (in direct messages)
15591559
"""
15601560
assert event["type"] == "typing"
15611561

zulipterminal/ui_tools/messages.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1017,7 +1017,7 @@ def keypress(self, size: urwid_Size, key: str) -> Optional[str]:
10171017
self.model.controller.view.middle_column.set_focus("footer")
10181018
elif is_command_key("EDIT_MESSAGE", key):
10191019
# User can't edit messages of others that already have a subject
1020-
# For private messages, subject = "" (empty string)
1020+
# For direct messages, subject = "" (empty string)
10211021
# This also handles the realm_message_content_edit_limit_seconds == 0 case
10221022
if (
10231023
self.message["sender_id"] != self.model.user_id
@@ -1089,7 +1089,7 @@ def keypress(self, size: urwid_Size, key: str) -> Optional[str]:
10891089
)
10901090
return key
10911091
else:
1092-
# The remaining case is of a private message not belonging to user.
1092+
# The remaining case is of a direct message not belonging to user.
10931093
# Which should be already handled by the topmost if block
10941094
raise RuntimeError(
10951095
"Reached unexpected block. This should be handled at the top."

zulipterminal/ui_tools/views.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,11 +46,11 @@
4646
from zulipterminal.server_url import near_message_url
4747
from zulipterminal.ui_tools.boxes import PanelSearchBox
4848
from zulipterminal.ui_tools.buttons import (
49+
PMButton,
4950
EmojiButton,
5051
HomeButton,
5152
MentionedButton,
5253
MessageLinkButton,
53-
PMButton,
5454
StarredButton,
5555
StreamButton,
5656
TopicButton,

0 commit comments

Comments
 (0)