Commit c7d735ff authored by mcramer's avatar mcramer
Browse files

Bugfix: previous bugfix was missing a thing

parent 95e8cecd
...@@ -981,7 +981,7 @@ class apache2_plugin { ...@@ -981,7 +981,7 @@ class apache2_plugin {
'rewrite_target_ssl' => $rewrite_target_ssl); 'rewrite_target_ssl' => $rewrite_target_ssl);
break; break;
default: default:
if(substr($alias['domain'], 0, 2) === '*.') $domain_rule = '(^|\.)'.$this->_rewrite_quote($alias['domain']); if(substr($alias['domain'], 0, 2) === '*.') $domain_rule = '(^|\.)'.$this->_rewrite_quote(substr($alias['domain'], 2));
else $domain_rule = '^'.$this->_rewrite_quote($alias['domain']); else $domain_rule = '^'.$this->_rewrite_quote($alias['domain']);
$rewrite_rules[] = array( 'rewrite_domain' => $domain_rule, $rewrite_rules[] = array( 'rewrite_domain' => $domain_rule,
'rewrite_type' => ($alias['redirect_type'] == 'no')?'':'['.$alias['redirect_type'].']', 'rewrite_type' => ($alias['redirect_type'] == 'no')?'':'['.$alias['redirect_type'].']',
......
...@@ -1172,7 +1172,7 @@ class nginx_plugin { ...@@ -1172,7 +1172,7 @@ class nginx_plugin {
unset($tmp_redirect_path); unset($tmp_redirect_path);
unset($tmp_redirect_path_parts); unset($tmp_redirect_path_parts);
} }
if(substr($alias['domain'], 0, 2) === '*.') $domain_rule = '(^|\.)'.$this->_rewrite_quote($alias['domain']); if(substr($alias['domain'], 0, 2) === '*.') $domain_rule = '(^|\.)'.$this->_rewrite_quote(substr($alias['domain'], 2));
else $domain_rule = '^'.$this->_rewrite_quote($alias['domain']); else $domain_rule = '^'.$this->_rewrite_quote($alias['domain']);
$rewrite_rules[] = array( 'rewrite_domain' => $domain_rule, $rewrite_rules[] = array( 'rewrite_domain' => $domain_rule,
'rewrite_type' => ($alias['redirect_type'] == 'no')?'':$alias['redirect_type'], 'rewrite_type' => ($alias['redirect_type'] == 'no')?'':$alias['redirect_type'],
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment