Fix check_url.

GitOrigin-RevId: 5d1323203cef7a8e74927daaa28fbdca364ffe32
This commit is contained in:
levlam 2020-05-03 15:27:26 +03:00
parent 91f79a41e7
commit 8826f2690d

View File

@ -323,7 +323,7 @@ Result<string> check_url(Slice url) {
return PSTRING() << (is_tg ? "tg" : "ton") << "://" << http_url.host_ << query; return PSTRING() << (is_tg ? "tg" : "ton") << "://" << http_url.host_ << query;
} }
if (url.find('.') == string::npos) { if (http_url.host_.find('.') == string::npos) {
return Status::Error("Wrong HTTP URL"); return Status::Error("Wrong HTTP URL");
} }
return http_url.get_url(); return http_url.get_url();