diff options
| author | Loyalsoldier <[email protected]> | 2024-10-22 04:46:12 +0800 |
|---|---|---|
| committer | Loyalsoldier <[email protected]> | 2024-10-22 04:46:12 +0800 |
| commit | 7e02a263a3108a768ae7fb25238e5a71a3aefd7a (patch) | |
| tree | 639df017ac99edfb87afc70259f8f1f80984e3c9 /plugin | |
| parent | 7cd219b11f9c98318b7915e15b93ed8e9c3dbe70 (diff) | |
Fix: reuse `private` list in previous steps
Diffstat (limited to 'plugin')
| -rw-r--r-- | plugin/special/private.go | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/plugin/special/private.go b/plugin/special/private.go index ec81acd1..4250c225 100644 --- a/plugin/special/private.go +++ b/plugin/special/private.go @@ -72,7 +72,11 @@ func (p *private) GetDescription() string { } func (p *private) Input(container lib.Container) (lib.Container, error) { - entry := lib.NewEntry(entryNamePrivate) + entry, found := container.GetEntry(entryNamePrivate) + if !found { + entry = lib.NewEntry(entryNamePrivate) + } + for _, cidr := range privateCIDRs { if err := entry.AddPrefix(cidr); err != nil { return nil, err |
