فهرست منبع

[slack] Reply with msg when user cant aaccess to query

Harshg999 4 سال پیش
والد
کامیت
f7488ab52c
1فایلهای تغییر یافته به همراه2 افزوده شده و 0 حذف شده
  1. 2 0
      desktop/core/src/desktop/lib/botserver/views.py

+ 2 - 0
desktop/core/src/desktop/lib/botserver/views.py

@@ -129,6 +129,8 @@ def handle_on_link_shared(channel_id, message_ts, links, user_id):
       slack_user = slack_user_check(user_id)
       user = User.objects.get(username=slack_user['user_email_prefix']) if not slack_user['is_bot'] else doc.owner
     except User.DoesNotExist:
+      bot_message = 'Corresponding Hue user not found or does not have access to the query'
+      _send_message(channel_id, bot_message)
       raise PopupException(_("Slack user does not have access to the query"))
 
     doc.can_read_or_exception(user)