File tree Expand file tree Collapse file tree 2 files changed +8
-8
lines changed Expand file tree Collapse file tree 2 files changed +8
-8
lines changed Original file line number Diff line number Diff line change @@ -1267,10 +1267,10 @@ func (s *CoreInstanceResourceCrud) Delete() error {
12671267 request .PreserveBootVolume = & tmp
12681268 }
12691269
1270- // if preserveDataVolumes, ok := s.D.GetOkExists("preserve_data_volumes"); ok {
1271- // tmp := preserveDataVolumes.(bool)
1272- // request.PreserveDataVolumes = &tmp
1273- // }
1270+ if preserveDataVolumes , ok := s .D .GetOkExists ("preserve_data_volumes" ); ok {
1271+ tmp := preserveDataVolumes .(bool )
1272+ request .PreserveBootVolume = & tmp
1273+ }
12741274
12751275 request .RequestMetadata .RetryPolicy = tfresource .GetRetryPolicy (s .DisableNotFoundRetries , "core" )
12761276
Original file line number Diff line number Diff line change @@ -5,7 +5,6 @@ package opsi
55
66import (
77 "context"
8-
98 "github.com/oracle/terraform-provider-oci/internal/client"
109 "github.com/oracle/terraform-provider-oci/internal/tfresource"
1110
@@ -110,14 +109,15 @@ func (s *OpsiHostInsightsDataSourceCrud) Get() error {
110109
111110 if hostType , ok := s .D .GetOkExists ("host_type" ); ok {
112111 interfaces := hostType .([]interface {})
113- tmp := make ([]oci_opsi.ListHostInsightsPlatformTypeEnum , len (interfaces ))
112+ tmp := make ([]oci_opsi.ListHostInsightsHostTypeEnum , len (interfaces ))
114113 for i := range interfaces {
115114 if interfaces [i ] != nil {
116- tmp [i ] = interfaces [i ].(oci_opsi.ListHostInsightsPlatformTypeEnum )
115+ hostType := interfaces [i ].(string )
116+ tmp [i ] = oci_opsi .ListHostInsightsHostTypeEnum (hostType )
117117 }
118118 }
119119 if len (tmp ) != 0 || s .D .HasChange ("host_type" ) {
120- // request.HostType = tmp
120+ request .HostType = tmp
121121 }
122122 }
123123
You can’t perform that action at this time.
0 commit comments