Merge branch 'master' into es17.01
This commit is contained in:
@@ -50,9 +50,24 @@ feature -- Basic operation
|
||||
do
|
||||
if active.is_available then
|
||||
active.process_email (a_email)
|
||||
import_errors (active)
|
||||
end
|
||||
if attached next as l_next and then l_next.is_available then
|
||||
l_next.process_email (a_email)
|
||||
import_errors (l_next)
|
||||
end
|
||||
end
|
||||
|
||||
feature {NONE} -- Errors
|
||||
|
||||
import_errors (a_mailer: NOTIFICATION_MAILER)
|
||||
do
|
||||
if attached a_mailer.last_errors as errs then
|
||||
across
|
||||
errs as ic
|
||||
loop
|
||||
report_error (ic.item)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
@@ -21,8 +21,21 @@ create
|
||||
feature {NONE} -- Initialization
|
||||
|
||||
make (a_smtp_server: READABLE_STRING_8)
|
||||
-- Create with smtp setting `user:password@hostname:port".
|
||||
local
|
||||
p,q: INTEGER
|
||||
do
|
||||
make_with_user (a_smtp_server, Void, Void)
|
||||
p := a_smtp_server.index_of ('@', 1)
|
||||
if p > 0 then
|
||||
q := a_smtp_server.index_of (':', 1)
|
||||
if q < p then
|
||||
make_with_user (a_smtp_server.substring (p + 1, a_smtp_server.count), a_smtp_server.substring (1, q -1), a_smtp_server.substring (q + 1, p -1))
|
||||
else
|
||||
make_with_user (a_smtp_server.substring (p + 1, a_smtp_server.count), a_smtp_server.substring (1, p -1), Void)
|
||||
end
|
||||
else
|
||||
make_with_user (a_smtp_server, Void, Void)
|
||||
end
|
||||
end
|
||||
|
||||
make_with_user (a_smtp_server: READABLE_STRING_8; a_user: detachable READABLE_STRING_8; a_password: detachable READABLE_STRING_8)
|
||||
|
||||
Reference in New Issue
Block a user