Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: 馃悰 resolve getPolicyDocumentOutput nil dereference (#1872) #1873

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
6 changes: 6 additions & 0 deletions sdk/go/aws/iam/getPolicyDocument.go
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,12 @@ func GetPolicyDocumentOutput(ctx *pulumi.Context, args GetPolicyDocumentOutputAr
ApplyT(func(v interface{}) (GetPolicyDocumentResult, error) {
args := v.(GetPolicyDocumentArgs)
r, err := GetPolicyDocument(ctx, &args, opts...)
if err != nil {
return nil, err
}
if r == nil {
return nil, fmt.Errorf("expected either result or error to be nil, not both")
}
return *r, err
}).(GetPolicyDocumentResultOutput)
}
Expand Down