Refactor OpenFunc call to use deferred execution
This commit is contained in:
parent
3489703ba7
commit
1f837afadc
12
api.go
12
api.go
@ -143,6 +143,18 @@ func New(options AgateOptions) (*Agate, error) {
|
||||
return agate, nil
|
||||
}
|
||||
|
||||
func (a *Agate) GetActiveDir() string {
|
||||
return a.options.BlobStore.GetActiveDir()
|
||||
}
|
||||
|
||||
func (a *Agate) GetMetadataDir() string {
|
||||
return a.metadataDir
|
||||
}
|
||||
|
||||
func (a *Agate) GetBlobsDir() string {
|
||||
return a.blobsDir
|
||||
}
|
||||
|
||||
// SaveSnapshot creates a new snapshot from the current state of the active directory.
|
||||
// If parentID is provided, it will be set as the parent of the new snapshot.
|
||||
// If parentID is empty, it will use the ID of the snapshot currently loaded in the active directory.
|
||||
|
Loading…
Reference in New Issue
Block a user