mirror of
https://github.com/letic/terraform-provider-google.git
synced 2024-07-03 08:42:39 +00:00
Add nil check to fix panic in storage bucket. (#2525)
This commit is contained in:
parent
e74ccfde23
commit
210141a5b1
|
@ -358,7 +358,7 @@ func resourceStorageBucketUpdate(d *schema.ResourceData, meta interface{}) error
|
|||
|
||||
// Setting fields to "" to be explicit that the PATCH call will
|
||||
// delete this field.
|
||||
if len(websites) == 0 {
|
||||
if len(websites) == 0 || websites[0] == nil {
|
||||
sb.Website.NotFoundPage = ""
|
||||
sb.Website.MainPageSuffix = ""
|
||||
} else {
|
||||
|
|
Loading…
Reference in New Issue
Block a user