Skip to content

Add debug logs for LinkedIn check#20

Open
dejarno wants to merge 2 commits into
mainfrom
dejarno-patch-1
Open

Add debug logs for LinkedIn check#20
dejarno wants to merge 2 commits into
mainfrom
dejarno-patch-1

Conversation

@dejarno

@dejarno dejarno commented Jan 8, 2026

Copy link
Copy Markdown
Owner

Added debug logging for LinkedIn presence.

Summary by Aikido

Security Issues: 0 🔍 Quality Issues: 1 Resolved Issues: 0

⚡ Enhancements

  • Added debug logging for LinkedIn presence and phone href

More info

Summary by CodeRabbit

  • Chores
    • Added internal development logging. No changes to features, public APIs, or app behavior; this is purely internal and has no user-facing impact.

Added debug logging for LinkedIn presence.
@coderabbitai

coderabbitai Bot commented Jan 8, 2026

Copy link
Copy Markdown
📝 Walkthrough

Walkthrough

Added three console.log debug statements to generateSignatureHtml in src/signature.ts to print a "debug:" label, the hasLinkedIn boolean, and the computed phoneHref. No control flow or exported API was changed.

Changes

Cohort / File(s) Summary
Debug logging addition
src/signature.ts
Inserted three console.log calls in generateSignatureHtml to emit a "debug:" label, the hasLinkedIn boolean, and the computed phoneHref for runtime tracing. No logic or return values were modified.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Poem

🐰 I hop through lines with gentle cheer,
Three tiny logs for eyes to peer,
"debug:" I whisper, flags in sight,
LinkedIn true, phoneHref bright,
A rabbit's note — your trace is clear!

🚥 Pre-merge checks | ✅ 2 | ❌ 1
❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'Add debug logs for LinkedIn check' directly and accurately describes the main change: adding console.log statements for debugging the LinkedIn presence check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch dejarno-patch-1

Tip

Issue Planner is now in beta. Read the docs and try it out! Share your feedback on Discord.


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.

@greptile-apps greptile-apps 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.

Your free trial has ended. If you'd like to continue receiving code reviews, you can add a payment method here.

@codspeed-hq

codspeed-hq Bot commented Jan 8, 2026

Copy link
Copy Markdown

Merging this PR will create unknown performance changes

⚠️ No benchmarks were detected in both the base of the PR and the PR.
Please ensure that your benchmarks are correctly instrumented with CodSpeed.

Check out the benchmarks creation guide


Comparing dejarno-patch-1 (e0a574f) with main (61e9d5e)

Open in CodSpeed

Comment thread src/signature.ts
const hasWebsite = Boolean(data.website);
const hasLinkedIn = Boolean(data.linkedinUrl);

console.log("debug:");

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Added console.log("debug:") and console.log(hasLinkedIn) debug prints; remove or guard them before committing to avoid leaking internal state and noisy logs.

Details

✨ AI Reasoning
​The change added ad-hoc console.log debug output (two console.log calls) into application logic. Leaving such debug prints in committed production code can leak internal state and clutter logs. These statements were not present before and were introduced by this diff.

🔧 How do I fix it?
Remove debugging statements like console.log, debugger, dd(), or logic bypasses like || true. Keep legitimate logging for monitoring and error handling.

Reply @AikidoSec feedback: [FEEDBACK] to get better review comments in the future.
Reply @AikidoSec ignore: [REASON] to ignore this issue.
More info

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

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

@AikidoSec ignore: it's just a test file

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

✅ Based on your feedback, we ignored this isssue because of the following reason:

it's just a test file

@coderabbitai coderabbitai 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.

Actionable comments posted: 1

🤖 Fix all issues with AI agents
In @src/signature.ts:
- Around line 25-26: Remove the stray console.log debug statements in
src/signature.ts (the calls printing "debug:" and hasLinkedIn); either delete
both console.log lines or replace them with a proper structured logger call
(e.g., use logger.debug with context like hasLinkedIn and redacted URL) so that
no plain console.debug output is left in production code and observability uses
the application logging facility.
📜 Review details

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 42f0d05 and a8ba361.

📒 Files selected for processing (1)
  • src/signature.ts

Comment thread src/signature.ts
Comment on lines +25 to +26
console.log("debug:");
console.log(hasLinkedIn);

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major

Remove debug logging before merging to production.

Console.log debug statements should not be committed to the main branch. These logs will clutter production output and provide minimal value without proper context or log levels.

🧹 Proposed fix: Remove debug logging
-  console.log("debug:");
-  console.log(hasLinkedIn);
-  

Alternatively, if observability is needed for LinkedIn presence tracking, consider implementing structured logging with appropriate log levels and context:

// Example with a proper logging framework
logger.debug('LinkedIn URL processing', { hasLinkedIn, linkedinUrl: data.linkedinUrl ? '[REDACTED]' : null });
🤖 Prompt for AI Agents
In @src/signature.ts around lines 25 - 26, Remove the stray console.log debug
statements in src/signature.ts (the calls printing "debug:" and hasLinkedIn);
either delete both console.log lines or replace them with a proper structured
logger call (e.g., use logger.debug with context like hasLinkedIn and redacted
URL) so that no plain console.debug output is left in production code and
observability uses the application logging facility.

Comment thread src/signature.ts
@sonarqubecloud

Copy link
Copy Markdown

@coderabbitai coderabbitai 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.

Actionable comments posted: 1

🤖 Fix all issues with AI agents
In `@src/signature.ts`:
- Line 30: Remove the debug print that exposes PII by deleting the
console.log(phoneHref) call in signature.ts (and any other leftover console.log
debug statements in that file); locate the phoneHref variable and the
surrounding code that builds the phone link and simply remove the console.log
invocation, or replace debug prints with a safe, non-PII logger call if you need
telemetry (e.g., log presence/length/masked value instead of the full phone
number).

Comment thread src/signature.ts

const mailtoHref = `mailto:${email}`;
const phoneHref = hasPhone ? `tel:${phone.replace(/[^\d+]/g, '')}` : '';
console.log(phoneHref);

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major

console.log(phoneHref) leaks user phone numbers to stdout.

Beyond being a debug artifact (same concern as the other console.log calls), this line outputs PII (phone numbers) to the console, which could end up in production logs or monitoring systems.

Remove this line along with the other debug statements.

🧹 Proposed fix
   const phoneHref = hasPhone ? `tel:${phone.replace(/[^\d+]/g, '')}` : '';
-  console.log(phoneHref);
   const websiteHref = hasWebsite
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
console.log(phoneHref);
const phoneHref = hasPhone ? `tel:${phone.replace(/[^\d+]/g, '')}` : '';
const websiteHref = hasWebsite
🤖 Prompt for AI Agents
In `@src/signature.ts` at line 30, Remove the debug print that exposes PII by
deleting the console.log(phoneHref) call in signature.ts (and any other leftover
console.log debug statements in that file); locate the phoneHref variable and
the surrounding code that builds the phone link and simply remove the
console.log invocation, or replace debug prints with a safe, non-PII logger call
if you need telemetry (e.g., log presence/length/masked value instead of the
full phone number).

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