Skip to content

resume data added#125

Merged
rushi-tekdi merged 1 commit into
tekdi:AI-assessmentfrom
rushi-tekdi:AI-Assessment
Jun 8, 2026
Merged

resume data added#125
rushi-tekdi merged 1 commit into
tekdi:AI-assessmentfrom
rushi-tekdi:AI-Assessment

Conversation

@rushi-tekdi

Copy link
Copy Markdown
Collaborator

No description provided.

@coderabbitai

coderabbitai Bot commented Jun 8, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: dc5928bf-3c31-4037-bd13-7480c7e00e19

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@rushi-tekdi
rushi-tekdi merged commit f248c41 into tekdi:AI-assessment Jun 8, 2026
1 check was pending
@sonarqubecloud

sonarqubecloud Bot commented Jun 8, 2026

Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Code Review

This pull request adds logic to update the resumeData field in the database when a tracking record already exists. The review feedback recommends replacing the raw SQL query with TypeORM's built-in repository update method to improve type safety and maintainability, as well as using modern TypeScript features like the nullish coalescing operator.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment on lines +242 to +250
//update resumeData
let temp_resumeData=createContentTrackingDto.resumeData ? createContentTrackingDto.resumeData : 0;
await this.dataSource.query(
`UPDATE content_tracking set "resumeData"=$2 WHERE "contentTrackingId"=$1`,
[
contentTrackingId,
temp_resumeData
],
);

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

Instead of using raw SQL queries via this.dataSource.query, it is highly recommended to use TypeORM's built-in repository methods (e.g., this.contentTrackingRepository.update). This ensures type safety, better maintainability, and leverages TypeORM's query optimization. Additionally, we can use the nullish coalescing operator (??) and const instead of let for cleaner, modern TypeScript code.

Suggested change
//update resumeData
let temp_resumeData=createContentTrackingDto.resumeData ? createContentTrackingDto.resumeData : 0;
await this.dataSource.query(
`UPDATE content_tracking set "resumeData"=$2 WHERE "contentTrackingId"=$1`,
[
contentTrackingId,
temp_resumeData
],
);
const resumeData = createContentTrackingDto.resumeData ?? 0;
await this.contentTrackingRepository.update(contentTrackingId, { resumeData });

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.

1 participant