refactor(settings): the slice's contracts and notes (P4b S4.2)
invoicing.first_number's refusal (LedgerError::FirstNumberLocked) lands as the contract the store's check raises once invoices carry numbers (S4.3): a series that has begun is never renumbered (B-40, A-2). Also: the settings invariants name the number prefix's bound, update_party's doc says which facts wait for documents_v2, and the email check no longer reads as a single-arm match. Terms is S4.1's as it landed; this slice no longer carries a copy.
This commit is contained in:
1 parent
02cb7f0254
commit
962b52c991
4 files changed
+19
-5
No files matched your search
@@ -4702,12 +4702,11 @@ impl Ledger {
|
||||
}
|
||||
}
|
||||
Archived(true) => {}
|
||||
Email(v) => match v {
|
||||
Some(e) => {
|
||||
crate::parties::check_email("email", e).map_err(LedgerError::InvalidParty)?
|
||||
Email(v) => {
|
||||
if let Some(e) = v {
|
||||
crate::parties::check_email("email", e).map_err(LedgerError::InvalidParty)?;
|
||||
}
|
||||
None => {}
|
||||
},
|
||||
}
|
||||
// Terms are typed and already canonical (`crate::Terms`), so
|
||||
// there is nothing here a string could get wrong.
|
||||
DefaultTermsAsCustomer(_) | DefaultTermsAsVendor(_) => {}
|
||||
|
||||
Reference in new issue
Block a user