diff --git a/tasks/main.yml b/tasks/main.yml
index 8ad338f4fc9d268e528effddade8def0ecc1b5c6..b6593dec420634dc1090e61d318e98e52f14743c 100644
--- a/tasks/main.yml
+++ b/tasks/main.yml
@@ -11,4 +11,4 @@
 
     - debug: msg='We have to implement some Drupal site specific configuration here'
 
-  when: not excluded_roles or "drupalconsole" not in excluded_roles and php_version_main|default("7") != "7"
+  when: (not excluded_roles or "drupalconsole" not in excluded_roles) and php_version_main|default("7") != "7"