Skip to content

Commit

Permalink
fix(instance_server): check empty bootscript (#2630)
Browse files Browse the repository at this point in the history
  • Loading branch information
Codelax authored Jun 21, 2024
1 parent 0632701 commit 4e7279e
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion internal/services/instance/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -612,7 +612,9 @@ func ResourceInstanceServerRead(ctx context.Context, d *schema.ResourceData, m i
_ = d.Set("zone", string(zone))
_ = d.Set("name", server.Name)
_ = d.Set("boot_type", server.BootType)
_ = d.Set("bootscript_id", server.Bootscript.ID)
if server.Bootscript != nil {
_ = d.Set("bootscript_id", server.Bootscript.ID)
}
_ = d.Set("type", server.CommercialType)
if len(server.Tags) > 0 {
_ = d.Set("tags", server.Tags)
Expand Down

0 comments on commit 4e7279e

Please sign in to comment.