You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Fixed: FS#778 - mailalias has priority over mailbox if they both exist. Added a error message that prevents it to add a alias or forward when a mailbox with the same email address exists.
Copy file name to clipboardExpand all lines: interface/web/mail/mail_alias_edit.php
+6-1Lines changed: 6 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
<?php
2
2
/*
3
-
Copyright (c) 2005, Till Brehm, projektfarm Gmbh
3
+
Copyright (c) 2005 - 2009, Till Brehm, projektfarm Gmbh
4
4
All rights reserved.
5
5
6
6
Redistribution and use in source and binary forms, with or without modification,
@@ -126,6 +126,11 @@ function onSubmit() {
126
126
unset($this->dataRecord["email_local_part"]);
127
127
unset($this->dataRecord["email_domain"]);
128
128
129
+
//* Check if there is no mailbox with this address
130
+
$tmp = $app->db->queryOneRecord("SELECT count(mailuser_id) as number FROM mail_user WHERE email = '".$app->db->quote($this->dataRecord["source"])."'");
Copy file name to clipboardExpand all lines: interface/web/mail/mail_forward_edit.php
+6-1Lines changed: 6 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
<?php
2
2
/*
3
-
Copyright (c) 2005, Till Brehm, projektfarm Gmbh
3
+
Copyright (c) 2005 - 2009, Till Brehm, projektfarm Gmbh
4
4
All rights reserved.
5
5
6
6
Redistribution and use in source and binary forms, with or without modification,
@@ -123,6 +123,11 @@ function onSubmit() {
123
123
unset($this->dataRecord["email_local_part"]);
124
124
unset($this->dataRecord["email_domain"]);
125
125
126
+
//* Check if there is no mailbox with this address
127
+
$tmp = $app->db->queryOneRecord("SELECT count(mailuser_id) as number FROM mail_user WHERE email = '".$app->db->quote($this->dataRecord["source"])."'");
$domain = $app->db->queryOneRecord("SELECT server_id, domain FROM mail_domain WHERE domain = '".$app->db->quote($_POST["email_domain"])."' AND ".$app->tform->getAuthSQL('r'));
//* Check if there is no alias or forward with this address
191
+
$tmp = $app->db->queryOneRecord("SELECT count(forwarding_id) as number FROM mail_forwarding WHERE source = '".$app->db->quote($this->dataRecord["email"])."'");
0 commit comments