@@ -77,57 +77,7 @@ impl User {
77
77
Self { raw : user }
78
78
}
79
79
80
- pub ( crate ) fn empty_with_hash_and_bot ( id : i64 , access_hash : Option < i64 > , bot : bool ) -> Self {
81
- Self {
82
- raw : tl:: enums:: User :: User ( tl:: types:: User {
83
- is_self : false ,
84
- contact : false ,
85
- mutual_contact : false ,
86
- deleted : false ,
87
- bot,
88
- bot_chat_history : false ,
89
- bot_nochats : false ,
90
- verified : false ,
91
- restricted : false ,
92
- min : false , // not min because the input hash is not a min hash
93
- bot_inline_geo : false ,
94
- support : false ,
95
- scam : false ,
96
- apply_min_photo : false ,
97
- fake : false ,
98
- bot_attach_menu : false ,
99
- premium : false ,
100
- attach_menu_enabled : false ,
101
- bot_can_edit : false ,
102
- close_friend : false ,
103
- stories_hidden : false ,
104
- stories_unavailable : true ,
105
- contact_require_premium : false ,
106
- bot_business : false ,
107
- bot_has_main_app : false ,
108
- id,
109
- access_hash,
110
- first_name : None ,
111
- last_name : None ,
112
- username : None ,
113
- phone : None ,
114
- photo : None ,
115
- status : None ,
116
- bot_info_version : None ,
117
- restriction_reason : None ,
118
- bot_inline_placeholder : None ,
119
- lang_code : None ,
120
- emoji_status : None ,
121
- usernames : None ,
122
- stories_max_id : None ,
123
- color : None ,
124
- profile_color : None ,
125
- bot_active_users : None ,
126
- } ) ,
127
- }
128
- }
129
-
130
- pub ( crate ) fn user ( & self ) -> Option < & tl:: types:: User > {
80
+ fn user ( & self ) -> Option < & tl:: types:: User > {
131
81
match & self . raw {
132
82
tl:: enums:: User :: User ( u) => Some ( u) ,
133
83
tl:: enums:: User :: Empty ( _) => None ,
0 commit comments