MCPcopy
hub / github.com/gogf/gf / formatTemplateObjectCreatingError

Method formatTemplateObjectCreatingError

os/gview/gview_parse.go:364–369  ·  view source on GitHub ↗

formatTemplateObjectCreatingError formats the error that created from creating the template object.

(filePath, tplName string, err error)

Source from the content-addressed store, hash-verified

362
363// formatTemplateObjectCreatingError formats the error that created from creating the template object.
364func (view *View) formatTemplateObjectCreatingError(filePath, tplName string, err error) error {
365 if err != nil {
366 return gerror.NewSkip(1, gstr.Replace(err.Error(), tplName, filePath))
367 }
368 return nil
369}
370
371// searchFile returns the absolute path of the `file` and its template folder path.
372// The returned `folder` is the template folder path, not the folder of the template file `path`.

Callers 1

getTemplateMethod · 0.95

Calls 3

NewSkipFunction · 0.92
ReplaceFunction · 0.92
ErrorMethod · 0.65

Tested by

no test coverage detected