randydev commited on
Commit
d09a97a
·
verified ·
1 Parent(s): 6784216

Update main.py

Browse files
Files changed (1) hide show
  1. main.py +4 -0
main.py CHANGED
@@ -50,6 +50,8 @@ client = Client(
50
 
51
  api = ak.PornoHub(key=API_KEY)
52
 
 
 
53
  @client.on_message(filters.command("start") & filters.private)
54
  async def welcome_start(client: Client, message: Message):
55
  keyboard = InlineKeyboardMarkup(
@@ -87,6 +89,8 @@ async def searchhub(client: Client, message: Message):
87
  if not query:
88
  return await message.reply_text("please search for pornohub.")
89
  pro = await message.reply_text("Processing.....")
 
 
90
  try:
91
  response = await api.x_search(query=query)
92
  link = response[0]
 
50
 
51
  api = ak.PornoHub(key=API_KEY)
52
 
53
+ not_allowed = ["hi", "hello", "hey", "hai", "help"]
54
+
55
  @client.on_message(filters.command("start") & filters.private)
56
  async def welcome_start(client: Client, message: Message):
57
  keyboard = InlineKeyboardMarkup(
 
89
  if not query:
90
  return await message.reply_text("please search for pornohub.")
91
  pro = await message.reply_text("Processing.....")
92
+ if query in not_allowed:
93
+ return await pro.edit_text("I don't understand, can you help me?")
94
  try:
95
  response = await api.x_search(query=query)
96
  link = response[0]