This message was deleted.
# typescript
s
This message was deleted.
t
Because they are different types from TypeScript pov. You’d need to add a type check/convertion.
g
Your type should be:
Copy code
export const getSigningKey = (
        secretKey: string | pulumi.Output<string>,
        region: pulumi.Output<digitalocean.Region> | pulumi.Output<aws.Region>
) => {...};
You accept either of the two outputs, not an output that can resolve to one of those regions
Also, it would be better if you use
pulumi.Input
as it includes passing the internal type directly or with a promise. Then in your function you can use
pulumi.output(region)
b
@green-school-95910 thanks, you're right that was an error on my part to not distinguish between either of two outputs and an output that could resolve to either. much appreciated.