diff --git a/README.md b/README.md index 832aac7..19686da 100644 --- a/README.md +++ b/README.md @@ -13,7 +13,7 @@ package for Elixir language. ## API The method names and arities/args are stable now. No change should be expected -on the package for the version `2.x.x` except any bug fixes. +on the package for the version `3.x.x` except any bug fixes. ## Installation diff --git a/bus.go b/bus.go index adb2fd0..47daac0 100644 --- a/bus.go +++ b/bus.go @@ -50,6 +50,7 @@ type ( Matcher string } + // EventOption is a function type to mutate event fields EventOption = func(Event) Event ctxKey int8 @@ -105,7 +106,7 @@ func WithSource(source string) EventOption { } } -// WithSource returns an option to set event's occurredAt field +// WithOccurredAt returns an option to set event's occurredAt field func WithOccurredAt(time time.Time) EventOption { return func(e Event) Event { e.OccurredAt = time