If an email was sent with empty "To:" and a proper alias in "CC:" (or any of the similar valid headers that conform the `rpc_tos_localparts` array), before 40ae36b7f8c412cd96dc9592d8d1fb90de1e52d2 the email wouldn't get rejected. After that commit it would get bounced.
This comes from the not-so-obvious new python idiom used, `all()`. Check this out:
```python
>>> all([False])
False
>>> all([])
True
```
So, apart from the fix introduced in that commit, which seems valid, we have to make sure `email_to_localparts` actually has contents. Otherwise we are producing false bounces here.
@Tecnativa TT23437
closesodoo/odoo#64528
X-original-commit: 8f094d3c01a6ad150b7945115cda515dbde1f4bc
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>