-
Notifications
You must be signed in to change notification settings - Fork 0
FEATURE: per-topic unsubscribe option in emails #9
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
base: email-notifications-enhancement
Are you sure you want to change the base?
FEATURE: per-topic unsubscribe option in emails #9
Conversation
|
@claude review this PR |
1 similar comment
|
@claude review this PR |
|
Claude finished @akshayutture-augment's task —— View job Code Review: Per-Topic Unsubscribe Option in EmailsI've completed a thorough review of this PR. Here are my findings: OverviewThis PR adds a per-topic unsubscribe feature that allows users to change their notification settings for specific topics directly from email notifications. The implementation spans backend (Rails), frontend (Ember.js), and email templates. 🔴 Critical Issues1. Missing Authentication/Authorization in Unsubscribe Route (Security)Location: The
Recommendation: Implement a secure token-based unsubscribe mechanism similar to the digest unsubscribe feature (see 2. Potential Nil Pointer ExceptionLocation: tu = TopicUser.find_by(user_id: current_user.id, topic_id: params[:topic_id])
if tu.notification_level > TopicUser.notification_levels[:regular]
tu.notification_level = TopicUser.notification_levels[:regular]
else
tu.notification_level = TopicUser.notification_levels[:muted]
end
tu.save!If no Recommendation: Add nil check or use tu = TopicUser.find_or_initialize_by(user_id: current_user.id, topic_id: params[:topic_id])
|
Test 2
Replicated from ai-code-review-evaluation/discourse-greptile#2