mirror of
https://github.com/stashapp/stash.git
synced 2025-12-18 12:54:38 +03:00
Dependency updates
This commit is contained in:
6
vendor/github.com/gobuffalo/packr/v2/pointer.go
generated
vendored
6
vendor/github.com/gobuffalo/packr/v2/pointer.go
generated
vendored
@@ -7,6 +7,8 @@ import (
|
||||
"github.com/pkg/errors"
|
||||
)
|
||||
|
||||
// Pointer is a resolvr which resolves
|
||||
// a file from a different box.
|
||||
type Pointer struct {
|
||||
ForwardBox string
|
||||
ForwardPath string
|
||||
@@ -14,6 +16,8 @@ type Pointer struct {
|
||||
|
||||
var _ resolver.Resolver = Pointer{}
|
||||
|
||||
// Resolve attempts to find the file in the specific box
|
||||
// with the specified key
|
||||
func (p Pointer) Resolve(box string, path string) (file.File, error) {
|
||||
plog.Debug(p, "Resolve", "box", box, "path", path, "forward-box", p.ForwardBox, "forward-path", p.ForwardPath)
|
||||
b, err := findBox(p.ForwardBox)
|
||||
@@ -25,5 +29,5 @@ func (p Pointer) Resolve(box string, path string) (file.File, error) {
|
||||
return f, errors.WithStack(errors.Wrap(err, path))
|
||||
}
|
||||
plog.Debug(p, "Resolve", "box", box, "path", path, "file", f)
|
||||
return f, nil
|
||||
return file.NewFileR(path, f)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user