Skip to content

Commit

Permalink
Remove unused timeoutFromContext func
Browse files Browse the repository at this point in the history
  • Loading branch information
jlegrone committed Mar 10, 2023
1 parent d1ee6c6 commit c9b68f5
Showing 1 changed file with 0 additions and 8 deletions.
8 changes: 0 additions & 8 deletions temporal/temporalite/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ package temporalite

import (
"os"
"time"

"context"
"fmt"
Expand Down Expand Up @@ -158,10 +157,3 @@ func (s *TemporaliteServer) NewClientWithOptions(ctx context.Context, options cl
func (s *TemporaliteServer) FrontendHostPort() string {
return s.frontendHostPort
}

func timeoutFromContext(ctx context.Context, defaultTimeout time.Duration) time.Duration {
if deadline, ok := ctx.Deadline(); ok {
return deadline.Sub(time.Now())
}
return defaultTimeout
}

0 comments on commit c9b68f5

Please sign in to comment.