Skip to content
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

Geir/max allowed message size stored in client object #60

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

ltgorm
Copy link
Contributor

@ltgorm ltgorm commented Nov 10, 2022

max size of messages was being retrieved from server and logged out but not stored and hence not accessible in mail client before sending.

The max allowed message size was already being parsed on the
greeting but not stored and hence the client could not build
logic on that. Now with this one can decide not to send if
the message is larger than the max allowed size.
src/client.js Outdated
@@ -70,6 +70,7 @@ class SmtpClient {
this._lastDataBytes = '' // Keep track of the last bytes to see how the terminating dot should be placed
this._envelope = null // Envelope object for tracking who is sending mail to whom
this._currentAction = null // Stores the function that should be run after a response has been received from the server
this._maxAllowedSize = 0 // Stores the max message size supported by the server as reported in the greeting
Copy link
Contributor

Choose a reason for hiding this comment

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

_ implies internal use but users of emailjs-imap-client will read this value

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants