Add Transaction Discard Comment

This commit is contained in:
Samuel Lorch 2023-04-02 02:00:00 +02:00
parent 27a2eabd82
commit 57fc5c0987

View file

@ -44,6 +44,8 @@ func (t *ConfigTransaction) Commit() error {
return nil return nil
} }
// Discard Discards the Transaction.
// Is a noop if The Transaction Already Finished due to a Commit() or another Discard()
func (t *ConfigTransaction) Discard() { func (t *ConfigTransaction) Discard() {
t.mutex.Lock() t.mutex.Lock()
defer t.mutex.Unlock() defer t.mutex.Unlock()