mirror of
https://github.com/SagerNet/sing-box.git
synced 2024-12-13 00:28:49 +00:00
19 lines
304 B
Go
19 lines
304 B
Go
|
package deprecated
|
||
|
|
||
|
import (
|
||
|
"context"
|
||
|
"github.com/sagernet/sing/service"
|
||
|
)
|
||
|
|
||
|
type Manager interface {
|
||
|
ReportDeprecated(feature Note)
|
||
|
}
|
||
|
|
||
|
func Report(ctx context.Context, feature Note) {
|
||
|
manager := service.FromContext[Manager](ctx)
|
||
|
if manager == nil {
|
||
|
return
|
||
|
}
|
||
|
manager.ReportDeprecated(feature)
|
||
|
}
|