Changeset fcd6964 in Klonkt for src/services/guardianship/handshake.js
- Timestamp:
- 07/24/2026 08:59:51 PM (7 weeks ago)
- Branches:
- main
- Children:
- c6185fa
- Parents:
- 3ffbedd
- File:
-
- 1 edited
-
src/services/guardianship/handshake.js (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
src/services/guardianship/handshake.js
r3ffbedd rfcd6964 64 64 65 65 /** Apply the local side of a commit: the ward writes its guardian, the 66 * candidate writes its ward. Each instance writes only what it hosts. */ 67 function applyCommitLocally(offer, handle) { 66 * candidate writes its ward. Each instance writes only what it hosts. 67 * other_handle is the human @handle for display (from the offer); the FEP 68 * escalation handle (candidate inbox) lives on the offer row, not here. */ 69 function applyCommitLocally(offer) { 68 70 const wardSlug = deps.localSlug(offer.ward_uri); 69 71 const candSlug = deps.localSlug(offer.candidate_uri); 70 if (wardSlug) relations.commitGuardianForWard(wardSlug, offer.candidate_uri, { handle , offerId: offer.offer_id });71 if (candSlug) relations.commitWardForGuardian(candSlug, offer.ward_uri, { handle , offerId: offer.offer_id });72 if (wardSlug) relations.commitGuardianForWard(wardSlug, offer.candidate_uri, { handle: offer.candidate_handle, offerId: offer.offer_id }); 73 if (candSlug) relations.commitWardForGuardian(candSlug, offer.ward_uri, { handle: offer.ward_handle, offerId: offer.offer_id }); 72 74 } 73 75 … … 80 82 if (!offer || !offers.readyToCommit(offer)) return null; 81 83 const done = offers.commit(slug, offerId, `${offer.candidate_uri}/inbox`); 82 if (done) { applyCommitLocally(done , done.handle); notify(slug, { kind: 'committed', ward: done.ward_uri, guardian: done.candidate_uri }); }84 if (done) { applyCommitLocally(done); notify(slug, { kind: 'committed', ward: done.ward_uri, guardian: done.candidate_uri }); } 83 85 return done; 84 86 }
Note:
See TracChangeset
for help on using the changeset viewer.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)