Skip to content

fix: remove console logs exposing user data and critical website flows #3845

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 13 commits into from
May 24, 2025

Conversation

sagarkori143
Copy link
Contributor

@sagarkori143 sagarkori143 commented Mar 8, 2025

This PR removes unnecessary console logs that were exposing user data and critical website flows in the browser console. Keeping these logs could lead to potential security risks and unintended data exposure.

image

Summary by CodeRabbit

  • Chores
    • Removed unnecessary logging from the newsletter subscription and discussion handling processes to streamline user experience.

Copy link
Contributor

coderabbitai bot commented Mar 8, 2025

Walkthrough

This pull request removes unnecessary console logging from two parts of the codebase. In the NewsletterSubscribe component, logging and ESLint disable comments in the handleSubmit function have been deleted. Similarly, a console log in the markAnswer function of the discussion background processing file has been removed. The changes do not affect the core control flow, error handling, or any public API declarations.

Changes

File Path Change Summary
components/NewsletterSubscribe.tsx Removed console logging and ESLint disable comments in the handleSubmit function.
netlify/functions/.../Reposity.ts Removed a console log statement from the markAnswer function.

Poem

I'm a happy rabbit with a coding spree,
Leaping over logs in pure harmony,
Debug prints vanished, quiet as the night,
Code now gleams with a cleaner light,
Hopping into a future bright! 🐰✨

Tip

⚡💬 Agentic Chat (Pro Plan, General Availability)
  • We're introducing multi-step agentic chat in review comments and issue comments, within and outside of PR's. This feature enhances review and issue discussions with the CodeRabbit agentic chat by enabling advanced interactions, including the ability to create pull requests directly from comments and add commits to existing pull requests.

📜 Recent review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 3e7598a and e2500a8.

📒 Files selected for processing (1)
  • components/NewsletterSubscribe.tsx (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • components/NewsletterSubscribe.tsx

🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai plan to trigger planning for file edits and PR creation.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link

netlify bot commented Mar 8, 2025

Deploy Preview for asyncapi-website ready!

Name Link
🔨 Latest commit b6bf03c
🔍 Latest deploy log https://app.netlify.com/projects/asyncapi-website/deploys/6831ad5061f7480008455595
😎 Deploy Preview https://deploy-preview-3845--asyncapi-website.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@sagarkori143 sagarkori143 changed the title Remove console logs exposing user data and critical website flows fix: Remove console logs exposing user data and critical website flows Mar 8, 2025
@sagarkori143 sagarkori143 changed the title fix: Remove console logs exposing user data and critical website flows fix: remove console logs exposing user data and critical website flows Mar 8, 2025
@sambhavgupta0705
Copy link
Member

@sagarkori143 checks are failing

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

📜 Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 6fdbfe0 and ab56b99.

📒 Files selected for processing (1)
  • components/NewsletterSubscribe.tsx (1 hunks)
🧰 Additional context used
🪛 ESLint
components/NewsletterSubscribe.tsx

[error] 88-88: Expected blank line before this statement.

(padding-line-between-statements)

🪛 GitHub Actions: PR testing - if Node project
components/NewsletterSubscribe.tsx

[error] 88-88: Expected blank line before this statement. padding-line-between-statements

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

♻️ Duplicate comments (1)
components/NewsletterSubscribe.tsx (1)

82-90: Good security practice: Removing console logs of user data.

I see you've removed the console log that was exposing response data (which likely contained user details) after the fetch call, which aligns with the PR's objective to remove unnecessary console logs that expose user data. This is a good security practice.

🧰 Tools
🪛 ESLint

[error] 88-88: Trailing spaces not allowed.

(no-trailing-spaces)


[error] 88-88: Delete ······

(prettier/prettier)

🪛 GitHub Actions: PR testing - if Node project

[error] 88-88: Trailing spaces not allowed. no-trailing-spaces


[error] 88-88: Delete ······ prettier/prettier

📜 Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between ab56b99 and 3e7598a.

📒 Files selected for processing (1)
  • components/NewsletterSubscribe.tsx (1 hunks)
🧰 Additional context used
🪛 ESLint
components/NewsletterSubscribe.tsx

[error] 88-88: Trailing spaces not allowed.

(no-trailing-spaces)


[error] 88-88: Delete ······

(prettier/prettier)

🪛 GitHub Actions: PR testing - if Node project
components/NewsletterSubscribe.tsx

[error] 88-88: Trailing spaces not allowed. no-trailing-spaces


[error] 88-88: Delete ······ prettier/prettier

⏰ Context from checks skipped due to timeout of 180000ms (2)
  • GitHub Check: Header rules - asyncapi-website
  • GitHub Check: Pages changed - asyncapi-website

Copy link

codecov bot commented Apr 11, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 100.00%. Comparing base (829bd73) to head (b6bf03c).
Report is 1 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff            @@
##            master     #3845   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           22        22           
  Lines          778       778           
  Branches       144       144           
=========================================
  Hits           778       778           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@sagarkori143
Copy link
Contributor Author

All issues have been resolved. PTAL!
@sambhavgupta0705

@akshatnema
Copy link
Member

/rtm

@asyncapi-bot asyncapi-bot merged commit 76a0983 into asyncapi:master May 24, 2025
18 of 19 checks passed
aminoxix pushed a commit to aminoxix/asyncapi-website that referenced this pull request Jun 4, 2025
asyncapi#3845)

Co-authored-by: Sagar Kori <[email protected]>
Co-authored-by: Chan <[email protected]>
Co-authored-by: Sambhav Gupta <[email protected]>
Co-authored-by: Akshat Nema <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants