MOHITKOURAV01 opened a new pull request, #9174:
URL: https://github.com/apache/pouchdb/pull/9174

   ### Modernize Query Planner: Replace manual mapping with `Object.values`
   
   This PR modernizes the `shouldShortCircuit` function in the `pouchdb-find` 
query planner. It resolves a legacy `@todo` comment by replacing a manual 
iteration over `Object.keys` with the native `Object.values()` method.
   
   ## Rationale
   - **Code Clarity**: `Object.values()` is more concise and directly expresses 
the intent of gathering all selector values.
   - **Modern Standards**: The codebase already uses `Object.values()` in other 
core modules, making this change consistent with current project standards.
   - **Tech Debt**: Removes an old Node.js v6 compatibility workaround that is 
no longer necessary.
   
   ## Changes
   - Modified 
[packages/node_modules/pouchdb-find/src/adapters/local/find/query-planner.js](cci:7://file:///Users/mohitkourav/Desktop/%20O%20S%20/pouchdb/packages/node_modules/pouchdb-find/src/adapters/local/find/query-planner.js:0:0-0:0)
   - Removed legacy `@todo` regarding Node.js v6 support.
   - Updated `shouldShortCircuit` to use `Object.values(selector)`.
   
   ## Testing Conducted
   - [x] Ran `npm run test-unit` (164/164 passing).
   - [x] Ran specialized `find` tests using `TYPE=find ADAPTERS=memory` 
(349/349 passing).
   - [x] Verified successful build via `npm run build`.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to