Skip to content

Commit

Permalink
add nil check to storagetransfer_job transfer schedule (#6634)
Browse files Browse the repository at this point in the history
  • Loading branch information
c2thorn authored Oct 3, 2022
1 parent 13f6fa6 commit 81e8258
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -839,7 +839,7 @@ func expandTransferSchedules(transferSchedules []interface{}) *storagetransfer.S
}

func flattenTransferSchedule(transferSchedule *storagetransfer.Schedule) []map[string]interface{} {
if reflect.DeepEqual(transferSchedule, &storagetransfer.Schedule{}) {
if transferSchedule == nil || reflect.DeepEqual(transferSchedule, &storagetransfer.Schedule{}) {
return nil
}

Expand Down

0 comments on commit 81e8258

Please sign in to comment.