mirror of
https://github.com/drakkan/sftpgo.git
synced 2024-11-21 23:20:24 +00:00
improve doc for dataprovider Close method
the method is used in test cases, it assumes that the dataprovider is initialized and it is not safe Initialize/Close from different goroutines
This commit is contained in:
parent
0b4ff97a1a
commit
fb8ccfe824
1 changed files with 3 additions and 1 deletions
|
@ -259,7 +259,9 @@ func GetUserByID(p Provider, ID int64) (User, error) {
|
|||
return p.getUserByID(ID)
|
||||
}
|
||||
|
||||
// Close releases all database resources
|
||||
// Close releases all provider resources.
|
||||
// This method is used in test cases.
|
||||
// Closing an uninitialized provider is not supported
|
||||
func Close(p Provider) error {
|
||||
availabilityTicker.Stop()
|
||||
availabilityTickerDone <- true
|
||||
|
|
Loading…
Reference in a new issue