Passed
Pull Request — main (#166)
by Yume
02:23
created

app/v2/handlers/utils.go   A

Size/Duplication

Total Lines 10
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 7
dl 0
loc 10
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A handlers.Render 0 3 1
1
package handlers
2
3
import (
4
	"github.com/a-h/templ"
5
	"github.com/labstack/echo/v4"
6
)
7
8
func Render(c echo.Context, _ int, t templ.Component) error {
9
	c.Response().Writer.Header().Set(echo.HeaderContentType, echo.MIMETextHTML)
10
	return t.Render(c.Request().Context(), c.Response())
11
}
12