From 1a4f2abca8e8bd69e3c909df069472c15a7f5207 Mon Sep 17 00:00:00 2001 From: Mikael Mattsson Date: Thu, 13 Aug 2015 13:15:46 +0200 Subject: [PATCH] Add compatibility with WPML and WooCommerce I experienced a conflict between Sage and a WPML and WooCommerce combination, where a translated product archive (specificly product_cat taxonomy page) wouldn't be wrapped in the base template. Just the template file contents would be executed without the master/base template. This could be solved by changeing the priority of the template_include filter for the wrapper to >100. I'm not sure if this is WooCommerce specific or if this would be the case for any translated taxonomy when using WPML. --- lib/wrapper.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/wrapper.php b/lib/wrapper.php index a819e381e8..72affb8293 100644 --- a/lib/wrapper.php +++ b/lib/wrapper.php @@ -61,4 +61,4 @@ public static function wrap($main) { return new SageWrapping(); } } -add_filter('template_include', [__NAMESPACE__ . '\\SageWrapping', 'wrap'], 99); +add_filter('template_include', [__NAMESPACE__ . '\\SageWrapping', 'wrap'], 109);