Skip to content

Commit

Permalink
Removes useless Pass method
Browse files Browse the repository at this point in the history
  • Loading branch information
EwenQuim committed Feb 1, 2024
1 parent 2868115 commit 3bca4bd
Showing 1 changed file with 0 additions and 10 deletions.
10 changes: 0 additions & 10 deletions ctx.go
Original file line number Diff line number Diff line change
Expand Up @@ -81,8 +81,6 @@ type ctx[B any] interface {
// return c.Redirect(301, "/recipes-list")
// })
Redirect(code int, url string) (any, error)

Pass() ContextNoBody
}

// NewContext returns a new context. It is used internally by Fuego. You probably want to use Ctx[B] instead.
Expand All @@ -107,10 +105,6 @@ type ContextWithBody[Body any] struct {
ContextNoBody
}

func (c *ContextWithBody[B]) Pass() ContextNoBody {
return c.ContextNoBody
}

// ContextNoBody is used when the controller does not have a body.
// It used as a base context for other Context types.
type ContextNoBody struct {
Expand Down Expand Up @@ -175,10 +169,6 @@ func (c ContextNoBody) Redirect(code int, url string) (any, error) {
return nil, nil
}

func (c ContextNoBody) Pass() ContextNoBody {
return c
}

func (c ContextNoBody) Context() context.Context {
return c.request.Context()
}
Expand Down

0 comments on commit 3bca4bd

Please sign in to comment.