Found while writing unit tests (#2). This one comes from reading the code; it has not been reproduced with a test or a real e-mail yet.
Problem
MailMessage::replace_body_vars (src/backend/mail.rs) builds the #summary# value by appending "{name}: {from} - {to}" for every reservation item without any separator. A booking with more than one item would be rendered as:
Court 1: 08:00 - 09:00Court 2: 10:00 - 11:00
Suggested fix
Join the items with a newline (or ", "), e.g. collect into a Vec<String> and join("\n"), and add a unit test with two items next to mail_message_replaces_variables.
Found while writing unit tests (#2). This one comes from reading the code; it has not been reproduced with a test or a real e-mail yet.
## Problem
`MailMessage::replace_body_vars` (`src/backend/mail.rs`) builds the `#summary#` value by appending `"{name}: {from} - {to}"` for every reservation item without any separator. A booking with more than one item would be rendered as:
```
Court 1: 08:00 - 09:00Court 2: 10:00 - 11:00
```
## Suggested fix
Join the items with a newline (or `", "`), e.g. collect into a `Vec<String>` and `join("\n")`, and add a unit test with two items next to `mail_message_replaces_variables`.
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Found while writing unit tests (#2). This one comes from reading the code; it has not been reproduced with a test or a real e-mail yet.
Problem
MailMessage::replace_body_vars(src/backend/mail.rs) builds the#summary#value by appending"{name}: {from} - {to}"for every reservation item without any separator. A booking with more than one item would be rendered as:Suggested fix
Join the items with a newline (or
", "), e.g. collect into aVec<String>andjoin("\n"), and add a unit test with two items next tomail_message_replaces_variables.