MCPcopy Index your code
hub / github.com/tinyplex/tinybase / getMergeableCellHashes

Function getMergeableCellHashes

docs/pseudo.esm.sh/tinybase@9.0.0/index.js:2832–2855  ·  view source on GitHub ↗
(otherTableRowHashes)

Source from the content-addressed store, hash-verified

2830 return [newRows, differingRowHashes];
2831 };
2832 const getMergeableCellHashes = (otherTableRowHashes) => {
2833 const cellHashes = {};
2834 objForEach(
2835 otherTableRowHashes,
2836 (otherRowHashes, tableId) => ifNotUndefined(
2837 mapGet(contentStampMap[0][0], tableId),
2838 ([rowStampMaps]) => objForEach(
2839 otherRowHashes,
2840 (otherRowHash, rowId) => ifNotUndefined(
2841 mapGet(rowStampMaps, rowId),
2842 ([cellStampMaps, , rowHash]) => rowHash !== otherRowHash ? mapForEach(
2843 cellStampMaps,
2844 (cellId, [, , cellHash]) => objEnsure(
2845 objEnsure(cellHashes, tableId, objNew),
2846 rowId,
2847 objNew
2848 )[cellId] = cellHash
2849 ) : 0
2850 )
2851 )
2852 )
2853 );
2854 return cellHashes;
2855 };
2856 const getMergeableCellDiff = (otherTableRowCellHashes) => {
2857 const [[tableStampMaps, tablesHlc]] = contentStampMap;
2858 const tablesObj = {};

Callers

nothing calls this directly

Calls 4

objForEachFunction · 0.70
mapGetFunction · 0.70
mapForEachFunction · 0.70
objEnsureFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…