added simple little before and after when editing a snippet
Summary by Sourcery
Enhance the snippet editing functionality by showing the previous content alongside the new content in the confirmation message when a snippet is edited.
Enhancements:
- Display the previous content of a snippet alongside the new content when a snippet is edited.
Reviewer's Guide by Sourcery
This pull request enhances the snippet editing functionality by adding a before and after comparison when a snippet is edited. The changes are implemented in the edit_snippet method of the snippets cog.
File-Level Changes
| Files | Changes |
|---|---|
tux/cogs/utility/snippets.py |
Added retrieval of the previous snippet content before editing |
tux/cogs/utility/snippets.py |
Modified the success message to include both the previous and new content of the edited snippet |
tux/cogs/utility/snippets.py |
Removed unnecessary comments about indentation |
Tips
- Trigger a new Sourcery review by commenting
@sourcery-ai reviewon the pull request. - Continue your discussion with Sourcery by replying directly to review comments.
- You can change your review settings at any time by accessing your dashboard:
- Enable or disable the Sourcery-generated pull request summary or reviewer's guide;
- Change the review language;
- You can always contact us if you have any questions or feedback.
i'll be changing this to embeds later on but currently this is what i doing for now
very spammy with large snippets, at least truncate each to 50 chars
added that for now
very spammy with large snippets, at least truncate each to 50 chars
added that for now
as kaizen said ill prob add buttons to view the before and after once i get to adding embeding
kaizen wants me to add an embed and buttons for viewing the before and after before merging it so i marked it as unfinished
ok