GC: Event: Add additional sanitization for restore (#2611)

## Description
Sanitization steps added for event transformation for restore. 
<!-- Insert PR description-->

## Does this PR need a docs update or release note?

- [x]  No 

## Type of change

- [x] 🐛 Bugfix


## Issue(s)

<!-- Can reference multiple issues. Use one of the following "magic words" - "closes, fixes" to auto-close the Github issue. -->
* closes #2490<issue>

## Test Plan

<!-- How will this be tested prior to merging.-->
- [x] 💪 Manual
This commit is contained in:
Danny 2023-02-23 12:45:36 -05:00 committed by GitHub
parent 81316250c4
commit 74eacd2ef8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -78,6 +78,12 @@ func ToEventSimplified(orig models.Eventable) models.Eventable {
newBody.SetOdataType(origBody.GetOdataType())
newBody.SetContent(&newContent)
orig.SetBody(newBody)
// Sanitation steps for Events
// See: https://github.com/alcionai/corso/issues/2490
orig.SetTransactionId(nil)
orig.SetWebLink(nil)
orig.SetICalUId(nil)
orig.SetId(nil)
return orig
}