here is the code implementation:
here is the key function:
here are the error messages :
The third argument should be a function with the following signature according to the docs:
k_eq : (K, K) -> Bool
I believe because you pass in a function call by specifying an argument,
key(callerId) would be evaluted to type
But the main problem is probably that your
updateJournal function takes a parameter called
key : ?Nat which has precedence over the function declaration outside of the method, thus the type error (they
key function and
key parameter have the same name).
I’m on mobile so I can’t fact check this, hope it helps anyways!
You were indeed correct. I completely missed the fact that recycled that name. Thank you so much!