From d613dda91d1f1595f73a967eb01c41b07cddacbe Mon Sep 17 00:00:00 2001
From: ThibG <thib@sitedethib.com>
Date: Sun, 21 Jan 2018 13:22:31 +0100
Subject: [PATCH] =?UTF-8?q?Fix=20assets=20loading=20when=20WEB=5FDOMAIN=20?=
 =?UTF-8?q?=E2=89=A0=20LOCAL=5FDOMAIN=20(#6319)?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Since 872a0d5bd801c998d911f7da582a60d2f714a710, assets URL are absolute and
not relative. Unfortunately, the domain used to build such URLs is the wrong
one: LOCAL_DOMAIN, and not WEB_DOMAIN, where the assets are stored.
---
 config/webpack/configuration.js | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/config/webpack/configuration.js b/config/webpack/configuration.js
index 26747e76b3..07af743f71 100644
--- a/config/webpack/configuration.js
+++ b/config/webpack/configuration.js
@@ -27,7 +27,7 @@ function formatPublicPath(host = '', path = '') {
 
 const output = {
   path: resolve('public', settings.public_output_path),
-  publicPath: formatPublicPath(env.ASSET_HOST || env.LOCAL_DOMAIN, settings.public_output_path),
+  publicPath: formatPublicPath(env.ASSET_HOST || env.WEB_DOMAIN || env.LOCAL_DOMAIN, settings.public_output_path),
 };
 
 module.exports = {
-- 
GitLab