diff --git a/langs/en.json b/langs/en.json
index bc5ede1e7..46841a56f 100644
--- a/langs/en.json
+++ b/langs/en.json
@@ -117,6 +117,7 @@
"long_not_64": "Given value is not 64 bytes long",
"array_invalid": "You didn't provide a valid array",
"predicate_not_set": "Predicate (value under _) was not set!",
+ "update_madelineproto": "You're running an old version of MadelineProto, an update is required!",
"type_extract_error": "Could not extract type \"%s\", you should update MadelineProto!",
"method_not_found": "Could not find method: ",
"params_missing": "Missing required parameter",
diff --git a/src/ApiWrappers/Start.php b/src/ApiWrappers/Start.php
index d246ff6c8..82f685221 100644
--- a/src/ApiWrappers/Start.php
+++ b/src/ApiWrappers/Start.php
@@ -23,6 +23,7 @@ namespace danog\MadelineProto\ApiWrappers;
use danog\MadelineProto\Exception;
use danog\MadelineProto\Lang;
use danog\MadelineProto\Magic;
+use danog\MadelineProto\MTProto;
use danog\MadelineProto\Settings;
use danog\MadelineProto\Tools;
@@ -84,7 +85,8 @@ trait Start
private function webAPIEcho(Settings $settings, string $message = ''): void
{
$message = \htmlentities($message);
- $title = \htmlentities(Lang::$current_lang['apiManualWeb']);
+ $title = MTProto::getWebWarnings();
+ $title .= \htmlentities(Lang::$current_lang['apiManualWeb']);
$title .= "
";
$title .= \sprintf(Lang::$current_lang['apiChooseManualAutoTipWeb'], 'https://docs.madelineproto.xyz/docs/SETTINGS.html');
$title .= "
$message";
diff --git a/src/MTProto.php b/src/MTProto.php
index f76b6382d..a837be87d 100644
--- a/src/MTProto.php
+++ b/src/MTProto.php
@@ -1624,7 +1624,7 @@ final class MTProto implements TLCallback, LoggerGetter
{
Logger::log($message);
- $warning = '';
+ $warning = $this->getWebWarnings();
if ($this->hasEventHandler()) {
if (!$this->hasReportPeers()) {
Logger::log('!!! '.Lang::$current_lang['noReportPeers'].' !!!', Logger::FATAL_ERROR);
@@ -1647,13 +1647,25 @@ final class MTProto implements TLCallback, LoggerGetter
}
}
}
+
+ return "