Maint: http proxy return concrete Loop struct

This commit is contained in:
Quentin McGaw (laptop)
2021-07-24 18:52:19 +00:00
parent 85540d96b6
commit 849dfee200
5 changed files with 12 additions and 12 deletions

View File

@@ -11,12 +11,12 @@ type Runner interface {
Run(ctx context.Context, done chan<- struct{})
}
func (l *looper) Run(ctx context.Context, done chan<- struct{}) {
func (l *Loop) Run(ctx context.Context, done chan<- struct{}) {
defer close(done)
crashed := false
if l.GetSettings().Enabled {
if l.state.GetSettings().Enabled {
go func() {
_, _ = l.statusManager.ApplyStatus(ctx, constants.Running)
}()
@@ -31,7 +31,7 @@ func (l *looper) Run(ctx context.Context, done chan<- struct{}) {
for ctx.Err() == nil {
runCtx, runCancel := context.WithCancel(ctx)
settings := l.GetSettings()
settings := l.state.GetSettings()
address := fmt.Sprintf(":%d", settings.Port)
server := New(runCtx, address, l.logger, settings.Stealth, settings.Log, settings.User, settings.Password)