summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoreportnov <eportnov@ibs.ru>2022-09-14 11:57:26 +0300
committereportnov <eportnov@ibs.ru>2022-09-14 11:57:26 +0300
commit4a1c272dc8c5bbc4cc75ca4b68b04bd4d1089383 (patch)
tree6b18789d83a05ef370657f1409cd839b13d805d0
parent224e56c630f2ef836dfe26581f584761abb45ed5 (diff)
downloadobmc-sila-smtp-4a1c272dc8c5bbc4cc75ca4b68b04bd4d1089383.tar.xz
temp fix checking mail
-rw-r--r--src/file/mail.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/file/mail.cpp b/src/file/mail.cpp
index 96d760b..5452136 100644
--- a/src/file/mail.cpp
+++ b/src/file/mail.cpp
@@ -51,7 +51,12 @@ namespace smtp::file
std::optional<std::string> Mail::GetMailFromLine( std::string const& line ) const
{
- //TODO parsing
+ //TODO registrator if checking parsing
+ auto pos = line.find('@');
+ if(pos == std::string::npos)
+ {
+ return {};
+ }
return line;
}