refactor logging options
This commit is contained in:
17
pkg/simple/client/notification/options.go
Normal file
17
pkg/simple/client/notification/options.go
Normal file
@@ -0,0 +1,17 @@
|
||||
package notification
|
||||
|
||||
type NotificationOptions struct {
|
||||
Endpoint string
|
||||
}
|
||||
|
||||
func NewNotificationOptions() *NotificationOptions {
|
||||
return &NotificationOptions{
|
||||
Endpoint: "",
|
||||
}
|
||||
}
|
||||
|
||||
func (s *NotificationOptions) ApplyTo(options *NotificationOptions) {
|
||||
if s.Endpoint != "" {
|
||||
options.Endpoint = s.Endpoint
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user