Function fetches viewer policies with confirmed value
Details
Details
- Reviewers
tomek atul - Commits
- rCOMMc389d36abeaf: [keyserver] add viewer acknowledgment fetcher
Check if returns proper value for one/multiple policies
Diff Detail
Diff Detail
- Repository
- rCOMM Comm
- Lint
Lint Not Applicable - Unit
Tests Not Applicable
Event Timeline
keyserver/src/fetchers/policy-acknowledgment-fetchers.js | ||
---|---|---|
13 ↗ | (On Diff #19175) | Do we have an index that will help us selecting it? |
13–15 ↗ | (On Diff #19175) | Why do we call append multiple times? I think it would be better to just have a multiline string. The only thing that needs append is mergeOrConditions. |
16 ↗ | (On Diff #19175) | Instead of using OR we can have IN condition. Usually IN is more readable and faster (might depend on the exact use case, db engine, etc.) |
lib/types/policy-types.js | ||
5–8 ↗ | (On Diff #19175) | We should use readonly where possible. Also the name is singular so it isn't a good idea to make a type an array. |
keyserver/src/fetchers/policy-acknowledgment-fetchers.js | ||
---|---|---|
13 ↗ | (On Diff #19175) | we have a primary key consisting user and policy columns so I think it should be okay |
16 ↗ | (On Diff #19175) | Good point, I missed that, thanks! |