GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Made DiscordMessageFile a more generic file container by AlexanderTPohl · Pull Request #2422 · DSharpPlus/DSharpPlus

Conversation

@AlexanderTPohl

@AlexanderTPohl AlexanderTPohl commented Mar 14, 2026

Copy link
Copy Markdown
Contributor
  • This pull request was written by AI
  • This pull request was assisted by AI, but you wrote the final code
  • This pull request did not involve AI in any way

Summary

Changed DiscordMessageFile to DiscordFile to be a more generic container for future use outside of the DiscordMessageBuilder and solved inconsistencys.

Details

Most of the AddFileOptions handling was moved to the build of the multipart request. The behaviour of the AddFileOptions remains the same.

Changes proposed

  • Renamed DiscordMessageFile to DiscordFile
  • Moved reset stream logic into the build request method and solved inconsistent stream resetting.
  • Added support for AddFileOptions.CloseStream and AddFileOptions.ResetStream outside of the MessageBuilder

Notes

  • All features in this pull request were tested.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@AlexanderTPohl
reworked DiscordMessageFile container
40bdc5f
akiraveliara
akiraveliara reviewed Mar 14, 2026
View reviewed changes
Comment thread DSharpPlus/Entities/BaseDiscordMessageBuilder.cs Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread DSharpPlus/Entities/DiscordFile.cs Resolved

Uh oh!

There was an error while loading. Please reload this page.

AlexanderTPohl added 2 commits March 15, 2026 10:48
@AlexanderTPohl
moved AddFileOptions to a seperate file
3910e20
@AlexanderTPohl
removed seperate MessageBuilder file disposing behaviour
27d105d
@AlexanderTPohl
AlexanderTPohl requested a review from akiraveliara March 15, 2026 10:18
akiraveliara
akiraveliara approved these changes Mar 15, 2026
View reviewed changes

@akiraveliara akiraveliara left a comment

Copy link
Copy Markdown
Member

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.

implementation looks good, got a few docs/code style picks

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread DSharpPlus/Net/Rest/MultipartRestRequest.cs Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread DSharpPlus/Net/Rest/MultipartRestRequest.cs Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread DSharpPlus/Entities/AddFileOptions.cs Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread DSharpPlus/Entities/AddFileOptions.cs Resolved

Uh oh!

There was an error while loading. Please reload this page.

@AlexanderTPohl
corrected codestyle and xmldocs
5794626
akiraveliara
akiraveliara approved these changes Mar 15, 2026
View reviewed changes
@akiraveliara
akiraveliara merged commit 6631045 into DSharpPlus:master Mar 15, 2026
1 check passed

Uh oh!

There was an error while loading. Please reload this page.

@akiraveliara akiraveliara mentioned this pull request Apr 3, 2026
v5 breaking changes tracking issue #1585
Open
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@akiraveliara akiraveliara akiraveliara approved these changes

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

2 participants

@AlexanderTPohl @akiraveliara
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.