Skip to content

Commit c5eda83

Browse files
author
Michael Roth
committed
fix(#465): Exclude php from command arguments
1 parent af2ee3a commit c5eda83

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

Resources/webpack/FosRouting.js

+6-1
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ class FosRouting {
2020
domain: [],
2121
php: 'php'
2222
};
23+
nonArgumentOptions = ['php'];
2324

2425
constructor(options = {}, registerCompileHooks = true) {
2526
this.options = Object.assign({target: 'var/cache/fosRoutes.json'}, this.default, options, {format: 'json'});
@@ -54,6 +55,10 @@ class FosRouting {
5455
}
5556
const compile = async (comp, callback) => {
5657
const args = Object.keys(this.options).reduce((pass, key) => {
58+
if (this.nonArgumentOptions.includes(key)) {
59+
return pass;
60+
}
61+
5762
const val = this.options[key];
5863
if (val !== this.default[key]) {
5964
if (Array.isArray(val)) {
@@ -82,7 +87,7 @@ class FosRouting {
8287
}
8388
callback();
8489
};
85-
90+
8691
if (this.registerCompileHooks === true) {
8792
compiler.hooks.beforeRun.tapAsync('RouteDump', compile);
8893
compiler.hooks.watchRun.tapAsync('RouteDump_Watch', (comp, callback) => {

0 commit comments

Comments
 (0)