Delete unused code

This commit is contained in:
2025-10-20 22:27:22 +02:00
parent 1ae28a0b09
commit d923732aba
4 changed files with 0 additions and 63 deletions

View File

@@ -100,32 +100,6 @@ func (p *instancePersister) save(inst *instance.Instance) error {
return nil
}
// Load loads a single instance from disk by name.
func (p *instancePersister) load(name string) (*instance.Instance, error) {
if !p.enabled {
return nil, fmt.Errorf("persistence is disabled")
}
if err := p.validateInstanceName(name); err != nil {
return nil, err
}
p.mu.Lock()
defer p.mu.Unlock()
instancePath := filepath.Join(p.instancesDir, name+".json")
inst, err := p.loadInstanceFile(name, instancePath)
if err != nil {
if os.IsNotExist(err) {
return nil, fmt.Errorf("instance %s not found", name)
}
return nil, err
}
return inst, nil
}
// Delete removes an instance's persistence file from disk.
func (p *instancePersister) delete(name string) error {
if !p.enabled {