From d318a4e8a20c70f971bb82771922a19a29bb4e33 Mon Sep 17 00:00:00 2001 From: Chris Hill-Scott Date: Wed, 3 Aug 2016 16:46:00 +0100 Subject: [PATCH] =?UTF-8?q?Don=E2=80=99t=20show=20banner=20on=20dashboard?= =?UTF-8?q?=20to=20API=20users?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The "you only have permission to view this service" banner sort of makes sense if you don’t have _any_ permissions, but it doesn’t if you have permission to create API keys. If you can create API keys you can do a lot more than just view the service. --- app/templates/views/dashboard/dashboard.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/templates/views/dashboard/dashboard.html b/app/templates/views/dashboard/dashboard.html index 536476cbb..b504b2a26 100644 --- a/app/templates/views/dashboard/dashboard.html +++ b/app/templates/views/dashboard/dashboard.html @@ -19,7 +19,7 @@ {% if not templates %} {% include 'views/dashboard/write-first-messages.html' %} {% endif %} - {% elif not current_user.has_permissions(['send_texts', 'send_emails', 'send_letters'], any_=True) %} + {% elif not current_user.has_permissions(['send_texts', 'send_emails', 'send_letters', 'manage_api_keys'], any_=True) %} {% include 'views/dashboard/no-permissions-banner.html' %} {% endif %}