From 11713f1ec880f43f9ce60301842a207413fa4162 Mon Sep 17 00:00:00 2001 From: Daniel Olson Date: Thu, 26 Feb 2015 16:39:53 -0500 Subject: [PATCH] Handle $dist_path as var Based on this thread: https://discourse.roots.io/t/sage-and-augmenting-my-workflow/2965/3 This sets up the opportunity to change the path of `dist/` for those needing to reference a different build. --- lib/assets.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/assets.php b/lib/assets.php index c090cfb..ed2dcfb 100644 --- a/lib/assets.php +++ b/lib/assets.php @@ -59,7 +59,7 @@ function asset_path($filename) { static $manifest; if (empty($manifest)) { - $manifest_path = get_template_directory() . '/dist/assets.json'; + $manifest_path = get_template_directory() . $dist_path . 'assets.json'; $manifest = new JsonManifest($manifest_path); } @@ -130,7 +130,7 @@ function jquery_local_fallback($src, $handle = null) { static $add_jquery_fallback = false; if ($add_jquery_fallback) { - echo '' . "\n"; + echo '' . "\n"; $add_jquery_fallback = false; } @@ -171,4 +171,3 @@ function google_analytics() { if (GOOGLE_ANALYTICS_ID) { add_action('wp_footer', __NAMESPACE__ . '\\google_analytics', 20); } -