Skip to content

Commit

Permalink
Updated delete custom domain aliases
Browse files Browse the repository at this point in the history
  • Loading branch information
willbrowningme committed Sep 26, 2019
1 parent 4bdeb4c commit 3703fba
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 11 deletions.
19 changes: 13 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -83,19 +83,16 @@ The limit is currently set to 10 which should suffice in the vast majority of si
When you delete your account the following happens:

* All of your recipients are deleted from the database
* All of your aliases are deleted from the database (aliases with a custom domain are soft deleted - see why below)
* All of your aliases are deleted from the database
* All of your custom domains are deleted from the database
* Your user details are deleted from the database
* Your username and any additional usernames you added are encrypted and added to a table in the database. This is to prevent anybody signing up with the same username in the future.
* Your username and any additional usernames that you created are encrypted and added to a table in the database. This is to prevent anybody signing up with the same username in the future.
* Any subscription information is deleted from the database

The reason aliases with a custom domain are soft deleted (a deleted_at column is filled in the database) is to ensure that nobody else can register your same domain in the future and then sign up to our site and receive emails for aliases you have previously used.

#### **Does this work with any email provider?**

Yes this will work with any provider, althought I can't guarantee it won't land in spam initially.


#### **Will people see my real email if I reply to a forwarded one?**

No, your real email will not be shown, the email will look as if it has come from us instead. Just make sure not to include anything that might identify you when composing the reply, i.e. your full name.
Expand Down Expand Up @@ -161,7 +158,17 @@ If you get close to your limit you'll be sent an email letting you know. If you

#### **I'm not receiving any emails, what's wrong?**

Please make sure to add [email protected] to your address book and check your spam folder. Make sure to mark emails from us as safe if they turn up in spam. If you still aren't receiving emails contact me.
Please make sure to add [email protected] to your address book and check your spam folder. Make sure to mark emails from us as safe if they turn up in spam.

Please also check that the senders domain is not in the [disposable-email-domains](https://github.com/ivolo/disposable-email-domains) list mentioned above, as these are blocked.

If an alias has been previously deleted and you try to send email to it, the emails will bounce with an error message - "554 5.7.1 Recipient address rejected: Access denied".

Check that you have not deactivated the alias, custom domain or additional username. When any of these are deactivated, emails will be silently discarded, they will not bounce or return any error message.

The sender of the email may be failing SPF, DMARC or DNS blacklist checks resulting in the email being rejected. The sender should also have correct reverse DNS setup and use a FQDN as their hostname.

If you still aren't receiving emails please contact me.

#### **How do I know this site won't disappear next month?**

Expand Down
3 changes: 1 addition & 2 deletions app/Jobs/DeleteAccount.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,7 @@ public function handle()
DeletedUsername::create(['username' => $this->user->username]);

$this->user->aliasRecipients()->delete();
$this->user->aliases()->whereNull('domain_id')->forceDelete();
$this->user->aliases()->delete();
$this->user->aliases()->forceDelete();
$this->user->recipients()->get()->each->delete(); // In order to fire deleting model event.
$this->user->domains()->delete();
$this->user->additionalUsernames()->get()->each->delete(); // In order to fire deleting model event.
Expand Down
5 changes: 2 additions & 3 deletions tests/Feature/SettingsTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -204,11 +204,10 @@ public function user_can_delete_account()
'user_id' => $this->user->id
]);

$this->assertDatabaseHas('aliases', [
$this->assertDatabaseMissing('aliases', [
'id' => $aliasWithCustomDomain->id,
'user_id' => $this->user->id,
'domain_id' => $domain->id,
'deleted_at' => now()
'domain_id' => $domain->id
]);

$this->assertDatabaseMissing('recipients', [
Expand Down

0 comments on commit 3703fba

Please sign in to comment.