File tree Expand file tree Collapse file tree 2 files changed +12
-4
lines changed Expand file tree Collapse file tree 2 files changed +12
-4
lines changed Original file line number Diff line number Diff line change @@ -43,9 +43,13 @@ func UpgradeResourceStateResponse(in *tfplugin5.UpgradeResourceState_Response) (
4343 if err != nil {
4444 return nil , err
4545 }
46- return & tfprotov5.UpgradeResourceStateResponse {
46+ resp := & tfprotov5.UpgradeResourceStateResponse {
4747 Diagnostics : diags ,
48- }, nil
48+ }
49+ if in .UpgradedState != nil {
50+ resp .UpgradedState = DynamicValue (in .UpgradedState )
51+ }
52+ return resp , nil
4953}
5054
5155func ReadResourceRequest (in * tfplugin5.ReadResource_Request ) (* tfprotov5.ReadResourceRequest , error ) {
Original file line number Diff line number Diff line change @@ -41,9 +41,13 @@ func UpgradeResourceState_Response(in *tfprotov5.UpgradeResourceStateResponse) (
4141 if err != nil {
4242 return nil , err
4343 }
44- return & tfplugin5.UpgradeResourceState_Response {
44+ resp := & tfplugin5.UpgradeResourceState_Response {
4545 Diagnostics : diags ,
46- }, nil
46+ }
47+ if in .UpgradedState != nil {
48+ resp .UpgradedState = DynamicValue (in .UpgradedState )
49+ }
50+ return resp , nil
4751}
4852
4953func ReadResource_Request (in * tfprotov5.ReadResourceRequest ) (* tfplugin5.ReadResource_Request , error ) {
You can’t perform that action at this time.
0 commit comments