diff options
author | Chocobozzz <florian.bigard@gmail.com> | 2016-10-02 15:39:09 +0200 |
---|---|---|
committer | Chocobozzz <florian.bigard@gmail.com> | 2016-10-02 15:39:09 +0200 |
commit | a6375e69668ea42e19531c6bc68dcd37f3f7cbd7 (patch) | |
tree | 03204a408d56311692c3528bedcf95d2455e94f2 /client/config/helpers.js | |
parent | 052937db8a8d282eccdbdf38d487ed8d85d3c0a7 (diff) | |
parent | c4403b29ad4db097af528a7f04eea07e0ed320d0 (diff) | |
download | PeerTube-a6375e69668ea42e19531c6bc68dcd37f3f7cbd7.tar.gz PeerTube-a6375e69668ea42e19531c6bc68dcd37f3f7cbd7.tar.zst PeerTube-a6375e69668ea42e19531c6bc68dcd37f3f7cbd7.zip |
Merge branch 'master' into webseed-merged
Diffstat (limited to 'client/config/helpers.js')
-rw-r--r-- | client/config/helpers.js | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/client/config/helpers.js b/client/config/helpers.js index 24d7dae9f..6268d2628 100644 --- a/client/config/helpers.js +++ b/client/config/helpers.js | |||
@@ -8,10 +8,15 @@ function hasProcessFlag (flag) { | |||
8 | return process.argv.join('').indexOf(flag) > -1 | 8 | return process.argv.join('').indexOf(flag) > -1 |
9 | } | 9 | } |
10 | 10 | ||
11 | function isWebpackDevServer () { | ||
12 | return process.argv[1] && !!(/webpack-dev-server$/.exec(process.argv[1])) | ||
13 | } | ||
14 | |||
11 | function root (args) { | 15 | function root (args) { |
12 | args = Array.prototype.slice.call(arguments, 0) | 16 | args = Array.prototype.slice.call(arguments, 0) |
13 | return path.join.apply(path, [ROOT].concat(args)) | 17 | return path.join.apply(path, [ROOT].concat(args)) |
14 | } | 18 | } |
15 | 19 | ||
16 | exports.hasProcessFlag = hasProcessFlag | 20 | exports.hasProcessFlag = hasProcessFlag |
21 | exports.isWebpackDevServer = isWebpackDevServer | ||
17 | exports.root = root | 22 | exports.root = root |