improved logging for preauth releaser
This commit is contained in:
@@ -21,7 +21,7 @@ const (
|
||||
)
|
||||
|
||||
/* ==============================
|
||||
Public Entry Point (LEGACY)
|
||||
Public Entry Point
|
||||
============================== */
|
||||
|
||||
func ReleasePreauthorizations(database *sql.DB) error {
|
||||
@@ -78,6 +78,7 @@ func handlePreauthRelease(
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
log.Infof("res=%s state=%s", info.transactionRes, info.transactionState)
|
||||
|
||||
// If already voided or declined → mark released
|
||||
if isAlreadyReleased(info) {
|
||||
@@ -86,8 +87,7 @@ func handlePreauthRelease(
|
||||
|
||||
// Only void approved + uncommitted
|
||||
if !isVoidable(info) {
|
||||
log.Infof("Preauth %s not eligible for void (res=%s state=%s)",
|
||||
ref, info.transactionRes, info.transactionState)
|
||||
log.Infof("Preauth %s not eligible for void (res=%s state=%s)", ref, info.transactionRes, info.transactionState)
|
||||
return nil
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user