diff options
author | ThibG <thib@sitedethib.com> | 2021-01-06 22:03:23 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-01-06 22:03:23 +0100 |
commit | d42e7e01dcd464f80637682d4eee6e5a7f36f26e (patch) | |
tree | 3a594f4d232cad40fa268d66539498db2ea217e2 /config/webpack/configuration.js | |
parent | 225c934a1b66e2fcbedbda7936666c1ca3c9a04b (diff) | |
parent | 55e84f9125608f12a7d29ec9bf9240e9a48cf4e5 (diff) |
Merge pull request #1482 from ThibG/glitch-soc/merge-upstream
Merge upstream changes
Diffstat (limited to 'config/webpack/configuration.js')
-rw-r--r-- | config/webpack/configuration.js | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/config/webpack/configuration.js b/config/webpack/configuration.js index b34ba0e0a..f05c888d5 100644 --- a/config/webpack/configuration.js +++ b/config/webpack/configuration.js @@ -2,19 +2,19 @@ const { basename, dirname, extname, join, resolve } = require('path'); const { env } = require('process'); -const { safeLoad } = require('js-yaml'); +const { load } = require('js-yaml'); const { lstatSync, readFileSync } = require('fs'); const glob = require('glob'); const configPath = resolve('config', 'webpacker.yml'); -const settings = safeLoad(readFileSync(configPath), 'utf8')[env.RAILS_ENV || env.NODE_ENV]; +const settings = load(readFileSync(configPath), 'utf8')[env.RAILS_ENV || env.NODE_ENV]; const flavourFiles = glob.sync('app/javascript/flavours/*/theme.yml'); const skinFiles = glob.sync('app/javascript/skins/*/*'); const flavours = {}; const core = function () { const coreFile = resolve('app', 'javascript', 'core', 'theme.yml'); - const data = safeLoad(readFileSync(coreFile), 'utf8'); + const data = load(readFileSync(coreFile), 'utf8'); if (!data.pack_directory) { data.pack_directory = dirname(coreFile); } @@ -23,7 +23,7 @@ const core = function () { for (let i = 0; i < flavourFiles.length; i++) { const flavourFile = flavourFiles[i]; - const data = safeLoad(readFileSync(flavourFile), 'utf8'); + const data = load(readFileSync(flavourFile), 'utf8'); data.name = basename(dirname(flavourFile)); data.skin = {}; if (!data.pack_directory) { |