diff options
| author | Ophestra <cat@gensokyo.uk> | 2025-10-29 03:40:09 +0900 |
|---|---|---|
| committer | Ophestra <cat@gensokyo.uk> | 2025-10-29 03:40:09 +0900 |
| commit | 274686d10d3386a41f8fb6bc3363269a734afe0e (patch) | |
| tree | 59ce81d5617cf5e1f67b819dab49b83b71d8ff93 /internal/app/path.go | |
| parent | 65342d588ff061d2130e6379d86a26be90c908ae (diff) | |
internal/validate: relocate from app
These are free of the dispatcher from internal/app. This change relocates them into their own package.
Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'internal/app/path.go')
| -rw-r--r-- | internal/app/path.go | 15 |
1 files changed, 0 insertions, 15 deletions
diff --git a/internal/app/path.go b/internal/app/path.go deleted file mode 100644 index 493dfe39..00000000 --- a/internal/app/path.go +++ /dev/null @@ -1,15 +0,0 @@ -package app - -import ( - "path/filepath" - "strings" -) - -func deepContainsH(basepath, targpath string) (bool, error) { - const upper = ".." + string(filepath.Separator) - - rel, err := filepath.Rel(basepath, targpath) - return err == nil && - rel != ".." && - !strings.HasPrefix(rel, upper), err -} |
