You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Strange that nobody has answered this question yet. Your document must comply with the AfterSaveHook interface (declared in collection.go). It means that you should only add AfterSave(*Collection) method, something like this:
typePersonstruct {
// ... same as in example
}
func (doc*Person) AfterSave(c*bongo.Collection) error {
// do somethingreturnnil
}
Can you give me a simple example?
Thanks
The text was updated successfully, but these errors were encountered: