forked from Silverfish/proton-bridge
Other: Clean locations on teardown
This commit is contained in:
@ -219,6 +219,7 @@ func withLocations(fn func(*locations.Locations) error) error {
|
|||||||
|
|
||||||
// Create a new locations object that will be used to provide paths to store files.
|
// Create a new locations object that will be used to provide paths to store files.
|
||||||
locations := locations.New(provider, constants.ConfigName)
|
locations := locations.New(provider, constants.ConfigName)
|
||||||
|
defer locations.Clean()
|
||||||
|
|
||||||
return fn(locations)
|
return fn(locations)
|
||||||
}
|
}
|
||||||
|
|||||||
@ -232,5 +232,6 @@ func (l *Locations) Clean() error {
|
|||||||
l.GetGuiLockFile(),
|
l.GetGuiLockFile(),
|
||||||
l.getLogsPath(),
|
l.getLogsPath(),
|
||||||
l.getUpdatesPath(),
|
l.getUpdatesPath(),
|
||||||
|
l.getGluonPath(),
|
||||||
).Do()
|
).Do()
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user