Update main.py
Browse files
main.py
CHANGED
@@ -53,13 +53,11 @@ api = ak.PornoHub(key=API_KEY)
|
|
53 |
|
54 |
not_allowed = ["hi", "hello", "hey", "hai", "help"]
|
55 |
|
56 |
-
@Client.on_message(filters.incoming & filters.
|
57 |
async def must_join_channel(bot: Client, msg: Message):
|
58 |
MUST_JOIN = "RendyProjects"
|
59 |
try:
|
60 |
-
if not (
|
61 |
-
await check_membership(MUST_JOIN, bot, msg)
|
62 |
-
):
|
63 |
force_button = InlineKeyboardMarkup(
|
64 |
[
|
65 |
[
|
@@ -79,7 +77,7 @@ async def must_join_channel(bot: Client, msg: Message):
|
|
79 |
reply_markup=force_button
|
80 |
)
|
81 |
await msg.stop_propagation()
|
82 |
-
except
|
83 |
pass
|
84 |
|
85 |
async def check_membership(channel_id, bot, msg):
|
|
|
53 |
|
54 |
not_allowed = ["hi", "hello", "hey", "hai", "help"]
|
55 |
|
56 |
+
@Client.on_message(filters.incoming & filters.private)
|
57 |
async def must_join_channel(bot: Client, msg: Message):
|
58 |
MUST_JOIN = "RendyProjects"
|
59 |
try:
|
60 |
+
if not await check_membership(MUST_JOIN, bot, msg):
|
|
|
|
|
61 |
force_button = InlineKeyboardMarkup(
|
62 |
[
|
63 |
[
|
|
|
77 |
reply_markup=force_button
|
78 |
)
|
79 |
await msg.stop_propagation()
|
80 |
+
except Exception:
|
81 |
pass
|
82 |
|
83 |
async def check_membership(channel_id, bot, msg):
|