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

Fix use imap username for smtp #253

Merged

Conversation

stan-janssen
Copy link
Contributor

This PR fixes a bug in the flow for setting up a new IMAP account.

Situation

The situation is as follows:

  • I enter my Name, E-mail Address, Password and Display Name on the first page of the setup screen.
  • The second page allows me to configure the IMAP and SMTP servers.
  • I want to use the same credentials for the IMAP and SMTP server, so I leave the option 'Use IMAP Credentials' on for the SMTP section (default)
  • I change my username for the IMAP server from the default value, which is my e-mail address, to the required value, which is the part before the @ symbol
  • When I try to save the account settings, the SMTP section will still use the default value for the username, the full e-mail address, instead of whatever I entered in the IMAP field.

Solution

I added two commits to fix this.

  1. The first and primary one makes sure that we pass the IMAP username to the SMTP transport auth extension if the 'Use IMAP Credentials' option is active. This solves the original problem.
  2. The second commit makes sure that as long as the Use IMAP Credentials option is active, and the user changes whatever is input into the IMAP username field, the (now hidden) SMTP username field is updated as well. When the user does decide to deactivate the Use IMAP Credentials option, the starting point is now the current IMAP username.

These fixes were tested on ElementaryOS 7 with the latest updates, and seem to work fine.

Stan Janssen and others added 2 commits March 25, 2023 09:15
When the option 'Use IMAP Credentials' is active for the SMTP server settings,
it would not use what the user entered in the IMAP credentials field. Instead,
it would use the default value for the username, which was the e-mail address.

This change ensures that the SMTP username matches the IMAP username whenever
that setting is used.
This is a minor improvement that syncs the value of the SMTP username field to
the input of the IMAP username field as long as the 'Use IMAP Credentials'
option is active.
@stan-janssen
Copy link
Contributor Author

This fixes #239.

src/Dialogs/Imap/ImapDialog.vala Show resolved Hide resolved
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