From d268fd1dc7ec48bb0c1cfba4c16b75c1cb20143d Mon Sep 17 00:00:00 2001 From: Rich Trott Date: Thu, 3 Oct 2019 02:48:24 -0700 Subject: [PATCH] Make execa compatible with Node.js 13.0.0-pre (#370) --- index.js | 2 +- readme.md | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/index.js b/index.js index 8b9df5fcc..454fc8f9c 100644 --- a/index.js +++ b/index.js @@ -189,7 +189,7 @@ module.exports.sync = (file, args, options) => { code: result.status, command, parsed, - timedOut: result.error && result.error.errno === 'ETIMEDOUT', + timedOut: result.error && result.error.code === 'ETIMEDOUT', isCanceled: false, killed: result.signal !== null }); diff --git a/readme.md b/readme.md index b5633f2af..db5ee168a 100644 --- a/readme.md +++ b/readme.md @@ -66,7 +66,7 @@ const execa = require('execa'); /* { message: 'Command failed with exit code 2 (ENOENT): wrong command spawn wrong ENOENT', - errno: 'ENOENT', + errno: -2, syscall: 'spawn wrong', path: 'wrong', spawnargs: ['command'], @@ -105,7 +105,7 @@ try { /* { message: 'Command failed with exit code 2 (ENOENT): wrong command spawnSync wrong ENOENT', - errno: 'ENOENT', + errno: -2, syscall: 'spawnSync wrong', path: 'wrong', spawnargs: ['command'],