mirror of
https://github.com/status-im/liquid-funding.git
synced 2025-02-16 21:36:46 +00:00
cancelPledge getOldestPledgeNotCanceled
This will eliminate the bug when pledge.oldPledge is a canceled project w/ a plugin and the plugin rejects transfers when canceled. This would prevent the pledge from being canceled. We address this by transfering the pledge amount to the oldestPledgeNotCanceled.
This commit is contained in:
parent
420d07d161
commit
34adef5505
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -651,7 +651,8 @@ function donate(uint64 idGiver, uint64 idReceiver) payable {
|
||||
PledgeAdmin storage m = findAdmin(n.owner);
|
||||
checkAdminOwner(m);
|
||||
|
||||
doTransfer(idPledge, n.oldPledge, amount);
|
||||
uint64 oldPledge = getOldestPledgeNotCanceled(n.oldPledge);
|
||||
doTransfer(idPledge, oldPledge, amount);
|
||||
}
|
||||
|
||||
|
||||
|
@ -651,7 +651,8 @@ function donate(uint64 idGiver, uint64 idReceiver) payable {
|
||||
PledgeAdmin storage m = findAdmin(n.owner);
|
||||
checkAdminOwner(m);
|
||||
|
||||
doTransfer(idPledge, n.oldPledge, amount);
|
||||
uint64 oldPledge = getOldestPledgeNotCanceled(n.oldPledge);
|
||||
doTransfer(idPledge, oldPledge, amount);
|
||||
}
|
||||
|
||||
|
||||
|
@ -237,7 +237,8 @@ function donate(uint64 idGiver, uint64 idReceiver) payable {
|
||||
PledgeAdmin storage m = findAdmin(n.owner);
|
||||
checkAdminOwner(m);
|
||||
|
||||
doTransfer(idPledge, n.oldPledge, amount);
|
||||
uint64 oldPledge = getOldestPledgeNotCanceled(n.oldPledge);
|
||||
doTransfer(idPledge, oldPledge, amount);
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user