Closed timothysparg closed 5 years ago
On the https://docs.atomist.com/developer/commands/ page there is the following code snippet:
import { HandlerResult, NoParameters } from "@atomist/automation-client"; import { CommandListenerInvocation } from "@atomist/sdm"; export async function helloWorldListener(ci: CommandListenerInvocation<NoParameters>): Promise<HandlerResult> { return ci.addressChannels("Hello, world"); }
however when you execute atomist start --local you are presnted with the following error
atomist start --local
lib/machine/machine.ts:53:5 - error TS2322: Type 'void' is not assignable to type 'HandlerResult'.
changing the method signature to return Promise<void> resolves the issue
Promise<void>
On the https://docs.atomist.com/developer/commands/ page there is the following code snippet:
however when you execute
atomist start --local
you are presnted with the following errorchanging the method signature to return
Promise<void>
resolves the issue