-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Remove dead code from Notifications #24104
base: trunk
Are you sure you want to change the base?
Conversation
Generated by 🚫 Danger |
|
App Name | ![]() |
|
Configuration | Release-Alpha | |
Build Number | pr24104-a9adaff | |
Version | 25.7.1 | |
Bundle ID | org.wordpress.alpha | |
Commit | a9adaff | |
App Center Build | WPiOS - One-Offs #11533 |
|
App Name | ![]() |
|
Configuration | Release-Alpha | |
Build Number | pr24104-a9adaff | |
Version | 25.7.1 | |
Bundle ID | com.jetpack.alpha | |
Commit | a9adaff | |
App Center Build | jetpack-installable-builds #10565 |
return false | ||
} | ||
return block.action(id: ReplyToCommentAction.actionIdentifier())?.on ?? false | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this variable always false
? If not, replyTextView
may appear in the UI and is now removed from this PR.
case .comment: | ||
return NoteBlockCommentTableViewCell.reuseIdentifier() | ||
case .actions: | ||
return NoteBlockActionsTableViewCell.reuseIdentifier() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure what's going on here. Do we just not handle these two kinds of content, and let if fall to the default
case and use the a default cell?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's a good point. This code is extremely hard to follow because it's parsing notification payload returned by the server. I'd suggest that instead of removing this code right away, let's add wpAssertionFailure
in every code path we think can be removed, and then remove the code only when we are confident it's dead.
2e6b354
to
a9adaff
Compare
To the best of my knowledge, the code that displays comments in NotificationDetailsViewController is also dead. The app has been using NotificationCommentDetailViewController with its underlying CommentDetailViewController for a while now instead.
To test:
Regression Notes
Potential unintended areas of impact
What I did to test those areas of impact (or what existing automated tests I relied on)
What automated tests I added (or what prevented me from doing so)
PR submission checklist:
RELEASE-NOTES.txt
if necessary.Testing checklist: