fix(nextcloud-mail-sync): portable email parsing

This commit is contained in:
Brad Stein 2026-01-03 07:06:30 -03:00
parent a76d944433
commit c165087eda

View File

@ -32,8 +32,8 @@ list_mail_accounts() {
next;
}
id != "" && /@/ {
if (match($0, /[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\.[A-Za-z]{2,}/, m)) {
printf("%s\t%s\n", id, m[0]);
if (match($0, /[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\.[A-Za-z]{2,}/)) {
printf("%s\t%s\n", id, substr($0, RSTART, RLENGTH));
id="";
}
}