@@ -5,6 +5,39 @@ use soroban_sdk::contracterror;
55#[ derive( Copy , Clone , Debug , Eq , PartialEq ) ]
66#[ repr( u32 ) ]
77pub enum ContractError {
8+ NotAuthorized = 1 ,
9+ InvoiceNotFound = 2 ,
10+ DeadlinePassed = 3 ,
11+ AlreadyFunded = 4 ,
12+ InvalidAmount = 5 ,
13+ InvoiceFrozen = 6 ,
14+ InvalidStatus = 7 ,
15+ PayerNotAllowed = 8 ,
16+ FundingInsufficient = 9 ,
17+ NotAuthorized = 1 ,
18+ InvoiceNotFound = 2 ,
19+ DeadlinePassed = 3 ,
20+ AlreadyFunded = 4 ,
21+ InvalidAmount = 5 ,
22+ InvoiceFrozen = 6 ,
23+ InvalidStatus = 7 ,
24+ PayerNotAllowed = 8 ,
25+ FundingInsufficient = 9 ,
26+ OracleCallFailed = 10 ,
27+ NotArbiter = 11 ,
28+ NotDisputed = 12 ,
29+ AlreadyExecuted = 13 ,
30+ TimelockPending = 14 ,
31+ ContractPaused = 15 ,
32+ InvalidRecipients = 16 ,
33+ PrerequisiteNotMet = 17 ,
34+ BatchLimitExceeded = 18 ,
35+ /// Issue #330: Recipient has already been paid on this invoice.
36+ RecipientAlreadyPaid = 19 ,
37+ /// Issue #327: Funds are still time-locked and cannot be released yet.
38+ FundsLockedUntil = 20 ,
39+ /// Aggregate protocol statistics would exceed their numeric bounds.
40+ StatsOverflow = 21 ,
841 NotAuthorized = 1 ,
942 InvoiceNotFound = 2 ,
1043 DeadlinePassed = 3 ,
@@ -29,4 +62,11 @@ pub enum ContractError {
2962 FundsLockedUntil = 20 ,
3063 /// Aggregate protocol statistics would overflow their storage type.
3164 StatsOverflow = 21 ,
65+ /// Issue #327: Funds are still time-locked and cannot be released yet.
66+ FundsLockedUntil = 20 ,
67+ /// Issue #330: Recipient has already been paid on this invoice.
68+ RecipientAlreadyPaid = 19 ,
69+ /// Oracle-priced invoice: the configured price oracle is unreachable, trapped, or
70+ /// returned a non-positive rate at payment time.
71+ OracleUnavailable = 21 ,
3272}
0 commit comments