mirror of
https://github.com/zitadel/zitadel.git
synced 2025-01-05 22:52:46 +00:00
37 lines
571 B
Go
37 lines
571 B
Go
package member
|
|
|
|
import (
|
|
"context"
|
|
|
|
"github.com/caos/zitadel/internal/eventstore/v2"
|
|
)
|
|
|
|
type MemberRemovedEvent struct {
|
|
eventstore.BaseEvent `json:"-"`
|
|
|
|
UserID string `json:"userId"`
|
|
}
|
|
|
|
func (e *MemberRemovedEvent) CheckPrevious() bool {
|
|
return true
|
|
}
|
|
|
|
func (e *MemberRemovedEvent) Data() interface{} {
|
|
return e
|
|
}
|
|
|
|
func NewMemberRemovedEvent(
|
|
ctx context.Context,
|
|
eventType eventstore.EventType,
|
|
userID string,
|
|
) *MemberRemovedEvent {
|
|
|
|
return &MemberRemovedEvent{
|
|
BaseEvent: *eventstore.NewBaseEventForPush(
|
|
ctx,
|
|
eventType,
|
|
),
|
|
UserID: userID,
|
|
}
|
|
}
|