Skip to content

Conversation

@amitojsingh
Copy link
Collaborator

…token' field to Bani details extraction, and modified database query to include 'Token' field.

…token' field to Bani details extraction, and modified database query to include 'Token' field.
@amitojsingh amitojsingh requested a review from Copilot May 13, 2025 19:42
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR updates the BaniList component and related files to include a new "token" field for key extraction and details display in the Bani data. Key changes include:

  • Modifying the database query in db.js to select the Token column and include it in the result objects.
  • Adding a token property in the default Bani order and updating the extraction helper accordingly.
  • Changing the key extractor in BaniList.jsx to use the token field, with an added console log for debugging.

Reviewed Changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 2 comments.

File Description
src/database/db.js Updated SQL query and object construction to include token.
src/common/defaultBaniOrder.js Added token property in the default order object.
src/common/components/BaniList/baniOrderHelper.js Included token in the bani item details extraction.
src/common/components/BaniList/BaniList.jsx Changed key extraction to use token and added debug logging.

translit: getTranslitText(Transliterations, language),
});
}
console.log("Bani List", totalResults);
Copy link

Copilot AI May 13, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nitpick] The debug logging statement may be unintentionally left in production code; consider removing it or wrapping it under a debug flag.

Suggested change
console.log("Bani List", totalResults);
if (process.env.DEBUG) {
logMessage("Bani List", totalResults);
}

Copilot uses AI. Check for mistakes.
{
gurmukhi: "22 vwrW",
translit: "22 varaa(n)",
token:"22vwrW"
Copy link

Copilot AI May 13, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ensure that the token property is properly delimited; if the following property is 'folder', a trailing comma might be required to maintain valid syntax.

Suggested change
token:"22vwrW"
token:"22vwrW",

Copilot uses AI. Check for mistakes.
…added 'token' field to Bani details, and updated folder handling in baniOrderHelper for improved data structure consistency.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants