Skip to content

Commit

Permalink
addressing feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
sklppy88 committed Oct 30, 2024
1 parent d7713c1 commit c216c79
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ export class EncryptedLogPayload {
* Produces the same output as `decryptAsOutgoing`.
*
* @param ciphertext - The ciphertext for the log
* @param addressSecret - The incoming viewing secret key, used to decrypt the logs
* @param addressSecret - The address secret, used to decrypt the logs
* @returns The decrypted log payload
*/
public static decryptAsIncoming(
Expand Down
10 changes: 5 additions & 5 deletions yarn-project/pxe/src/synchronizer/synchronizer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -371,15 +371,15 @@ export class Synchronizer {

async #removeNullifiedNotes(notes: IncomingNoteDao[]) {
// now group the decoded incoming notes by public key
const publicKeyToIncomingNotes: Map<PublicKey, IncomingNoteDao[]> = new Map();
const addressPointToIncomingNotes: Map<PublicKey, IncomingNoteDao[]> = new Map();
for (const noteDao of notes) {
const notesForPublicKey = publicKeyToIncomingNotes.get(noteDao.addressPoint) ?? [];
notesForPublicKey.push(noteDao);
publicKeyToIncomingNotes.set(noteDao.addressPoint, notesForPublicKey);
const notesForAddressPoint = addressPointToIncomingNotes.get(noteDao.addressPoint) ?? [];
notesForAddressPoint.push(noteDao);
addressPointToIncomingNotes.set(noteDao.addressPoint, notesForAddressPoint);
}

// now for each group, look for the nullifiers in the nullifier tree
for (const [publicKey, notes] of publicKeyToIncomingNotes.entries()) {
for (const [publicKey, notes] of addressPointToIncomingNotes.entries()) {
const nullifiers = notes.map(n => n.siloedNullifier);
const relevantNullifiers: Fr[] = [];
for (const nullifier of nullifiers) {
Expand Down

0 comments on commit c216c79

Please sign in to comment.