« get me outta code hell

General improvements - http-music - Command-line music player + utils (not a server!)
about summary refs log tree commit diff
path: root/src/promisify-process.js
diff options
context:
space:
mode:
authorliam4 <towerofnix@gmail.com>2017-05-31 19:32:36 -0300
committerliam4 <towerofnix@gmail.com>2017-05-31 19:32:36 -0300
commit4b1a544510f436fac951c8d161c4fbce44c42580 (patch)
treedf7fc1716a892821202b123c52167a7168ecddbb /src/promisify-process.js
parent26663377fd7ea15a6c3d23a399d1266c8639d42e (diff)
General improvements
Diffstat (limited to 'src/promisify-process.js')
-rw-r--r--src/promisify-process.js5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/promisify-process.js b/src/promisify-process.js
index ca49b31..ef8d0c6 100644
--- a/src/promisify-process.js
+++ b/src/promisify-process.js
@@ -2,7 +2,8 @@
 
 module.exports = function promisifyProcess(proc, showLogging = true) {
   // Takes a process (from child_process) and returns a promise that resolves
-  // when the process exits.
+  // when the process exits (or rejects with a warning, if the exit code is
+  // non-zero).
 
   return new Promise((resolve, reject) => {
     if (showLogging) {
@@ -14,7 +15,7 @@ module.exports = function promisifyProcess(proc, showLogging = true) {
       if (code === 0) {
         resolve()
       } else {
-        console.error('Process failed!', proc.spawnargs)
+        console.error("Process failed!", proc.spawnargs)
         reject(code)
       }
     })