From aa26e83884a513a897ecfa0270bf265797785d28 Mon Sep 17 00:00:00 2001 From: Alexander Zeitler Date: Sun, 11 Apr 2021 01:16:15 +0200 Subject: [PATCH] refactor: use spread operator to build typed result --- src/index.ts | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/index.ts b/src/index.ts index 13650af..8527c22 100644 --- a/src/index.ts +++ b/src/index.ts @@ -366,9 +366,7 @@ export const port = async function ( const result = await execCompose('port', args, options) const [address, port] = result.out.split(':') return { - exitCode: result.exitCode, - out: result.out, - err: result.err, + ...result, result: { address, port: Number(port)