Unchecking "Enabled" for an alias does not disable it

Issue Description

Disabling an alias does not seem to work: doing so does not modify the alias’ behavior.

Expected Behavior

When an alias is disabled, emails sent to the corresponding account should not be received.

Actual Behavior

When trying to disable an alias to an existing account, emails sent to this alias is still being received in the account’s mailbox.

Reproduction Steps

The problem can be replicated in two scenarios:

1.1. Configure Stalwart with a domain and an account linked to it.
1.2. Configure an alias to this account within the same domain.
1.3. Check the alias is working by sending a test mail to its corresponding address
1.4 Disable the alias
1.5 Check the alias is still working by sending a test mail to its corresponding address

1.1. Configure Stalwart with a domain and an account linked to it.
1.2. Configure an alias to this account within the same domain, leaving it disabled
1.3. Check the alias is working nonetheless by sending a test mail to its corresponding address

Stalwart Version

v0.16.x

Installation Method

Docker

Database Backend

RocksDB

Blob Storage

RocksDB

Search Engine

Internal

Directory Backend

Internal

Additional Context

Hardware: Synology NAS DS920M+
Interface: Docker
Version: 0.16.6
No catch-all address is configured on the domain

I have reviewed the documentation and FAQ and confirm that my issue is NOT addressed there.

on

I have searched this support forum (open and closed topics) and confirm this is not a duplicate.

on

I understand that topics in this category are triaged by a bot first but a human reply will follow up. If I’d prefer a human-only reply, I’ll add the no-ai tag to my topic.

on

Let me research how alias enabling/disabling works in Stalwart.

This has been fixed on the main branch. The fix will be included in v0.16.8.

I have noticed today that the 0.16.8 version has been released and tested it: now enabling & disabling the aliases work as intended.

A big thank you for your help!

Best regards,

Celeri