From 0321088eaece2e694cd1f8ca979eb9755e1d4402 Mon Sep 17 00:00:00 2001 From: Paolo Mainardi Date: Mon, 12 Oct 2015 14:53:27 +0200 Subject: [PATCH] refs #6: Fix hook_init --- domain_path_rewrite.module | 3 +++ 1 file changed, 3 insertions(+) diff --git a/domain_path_rewrite.module b/domain_path_rewrite.module index aae9f5e..996ee80 100644 --- a/domain_path_rewrite.module +++ b/domain_path_rewrite.module @@ -4,6 +4,9 @@ * Implements hook_init(). */ function domain_path_rewrite_init() { + if (drupal_is_cli() || function_exists('drush_main')) { + return; + } if ($domain_path = _domain_path_rewrite_domain_path(current_path())) { global $_domain; if (!($_domain['domain_id'] == $domain_path['domain_id'] && request_path() == $domain_path['path'])) {