[lib] Use new hashing functions in state check
Summary:
Part of ENG-4959
Depends on D9327
Use the functions introduced in the previous diff. If the hashes are still not available (thread hashes are still being calculated) we just return true because the keyserver will send another state check in 3 minutes anyway.
Test Plan:
Set state check time to 20s and remove the version checking added in D9267.
- check that all whole-store hashes match
- update a thread and entry names in the keyserver db -> check that they are updated on the client during the next state check, only these specific hashes are wrong
- Increase the time it takes for integrity-handler to calculate all thread hashes, reload the web page and update a thread name in keyserver db
- for a few first state checks the thread hashes weren't yet calculated so state check passed
- after thread hashing completed, the thread got updated on next state check
Also checked that the hashes were correct after thread/entry were updated from state check
Reviewers: tomek, inka, kamil
Reviewed By: tomek
Subscribers: ashoat
Differential Revision: https://phab.comm.dev/D9328