mirror of
https://github.com/mudler/luet.git
synced 2025-08-02 07:59:22 +00:00
ConfigProtect: support annotation without initial /
This commit is contained in:
parent
6819a28f07
commit
e5f44eee09
@ -48,6 +48,9 @@ type ConfigProtect struct {
|
||||
}
|
||||
|
||||
func NewConfigProtect(annotationDir string) *ConfigProtect {
|
||||
if len(annotationDir) > 0 && annotationDir[0:1] != "/" {
|
||||
annotationDir = "/" + annotationDir
|
||||
}
|
||||
return &ConfigProtect{
|
||||
AnnotationDir: annotationDir,
|
||||
MapProtected: make(map[string]bool, 0),
|
||||
|
Loading…
Reference in New Issue
Block a user