Refactor some SQLiteQueryExecutor code
Summary: Refactor code handling Metadata table to avoid repeating code. Functions used before have been left as wrappers as suggested in comments on ENG-1979.
Test Plan:
Running the ios simulator. I feel like, since there is no functional change, and the changes are pretty simple, it should be enough to check if everything compiles, but if I should test
it more thoroughly please let me know.
Reviewers: marcin, przemek, michal, bartek, jon, ashoat, tomek
Reviewed By: marcin, przemek, bartek, ashoat, tomek
Subscribers: ashoat, tomek, atul, abosh
Differential Revision: https://phab.comm.dev/D5316