1
0
mirror of https://github.com/danog/MadelineProto.git synced 2024-11-30 07:38:58 +01:00
This commit is contained in:
Daniil Gentili 2023-08-13 12:19:39 +02:00
parent f9db44436c
commit 5c09a9a20f
Signed by: danog
GPG Key ID: 8C1BE3B34B230CA7
3 changed files with 11 additions and 2 deletions

View File

@ -143,7 +143,7 @@
"do_not_use_blocking_class": "for performance reasons, handlers may not use the non-async blocking class %s, please use %s, instead",
"do_not_use_deprecated_function": "the %s function is deprecated, please use %s, instead",
"do_not_use_non_root_require_in_event_handler": "for performance reasons, you must not use require or include inside of an event handler class, only root-level requires are allowed.",
"do_not_use_yield": "MadelineProto 8 does not require or support the use of yield in async functions, you can remove all yield keywords now",
"do_not_use_yield": "MadelineProto 8 does not require or support the use of yield in async functions, you must remove all yield keywords previously used for async function calls",
"recommend_not_use_filesystem_function": "usage of the %s function is not recommended, because accessing the filesystem during update handling will slow down your bot, please see https://docs.madelineproto.xyz/docs/UPDATES.html#avoiding-the-use-of-filesystem-functions for a list of alternative ways to store data that will not slow down your bot!",
"plugins_do_not_use_require": "for performance reasons, plugins can only automatically include or require other files present in the plugins folder by triggering the PSR-4 autoloader (not by manually require()'ing them).",

View File

@ -84,6 +84,7 @@ If you intentionally deleted this account, ignore this message.',
'do_not_use_blocking_function' => 'for performance reasons, event handlers may not use the non-async blocking function %s, please use %s, instead',
'do_not_use_deprecated_function' => 'the %s function is deprecated, please use %s, instead',
'do_not_use_non_root_require_in_event_handler' => 'for performance reasons, you must not use require or include inside of an event handler class, only root-level requires are allowed.',
'do_not_use_yield' => 'MadelineProto 8 does not require or support the use of yield in async functions, you must remove all yield keywords previously used for async function calls',
'done' => 'تەواو!',
'encode_double_error' => 'نەتوانرا بە باشی دووانە کۆد بکات',
'extensionRecommended' => 'Warning: the %s extension is not installed, please install it to speed up MadelineProto!',
@ -247,6 +248,7 @@ If you intentionally deleted this account, ignore this message.',
'do_not_use_blocking_function' => 'for performance reasons, event handlers may not use the non-async blocking function %s, please use %s, instead',
'do_not_use_deprecated_function' => 'the %s function is deprecated, please use %s, instead',
'do_not_use_non_root_require_in_event_handler' => 'for performance reasons, you must not use require or include inside of an event handler class, only root-level requires are allowed.',
'do_not_use_yield' => 'MadelineProto 8 does not require or support the use of yield in async functions, you must remove all yield keywords previously used for async function calls',
'done' => 'Done!',
'encode_double_error' => 'Could not properly encode double',
'extensionRecommended' => 'Warning: the %s extension is not installed, please install it to speed up MadelineProto!',
@ -410,6 +412,7 @@ If you intentionally deleted this account, ignore this message.',
'do_not_use_blocking_function' => 'به دلایل عملکردی و اجرایی، ایونت‌هندلرها نباید از فانکشن %s که async نیست استفاده کنند، لطفا به جای آن از %s استفاده کنید',
'do_not_use_deprecated_function' => 'تابع %s منسوخ شده، لطفا به جای آن از %s استفاده کنید',
'do_not_use_non_root_require_in_event_handler' => 'به دلایل عملکردی و اجرایی، شما نباید از require یا include داخل کلس ایونت‌هندلر استفاده کنید، فقط require های سطح root مجاز هستند.',
'do_not_use_yield' => 'MadelineProto 8 does not require or support the use of yield in async functions, you must remove all yield keywords previously used for async function calls',
'done' => 'انجام شد!',
'encode_double_error' => 'نمی‌توان به درستی double را رمزنگاری (انکد) کرد',
'extensionRecommended' => 'هشدار: افزونه %s نصب نشده است. لطفا برای افزایش سرعت مدلین‌پروتو آن را نصب کنید!',
@ -573,6 +576,7 @@ If you intentionally deleted this account, ignore this message.',
'do_not_use_blocking_function' => 'for performance reasons, event handlers may not use the non-async blocking function %s, please use %s, instead',
'do_not_use_deprecated_function' => 'the %s function is deprecated, please use %s, instead',
'do_not_use_non_root_require_in_event_handler' => 'for performance reasons, you must not use require or include inside of an event handler class, only root-level requires are allowed.',
'do_not_use_yield' => 'MadelineProto 8 does not require or support the use of yield in async functions, you must remove all yield keywords previously used for async function calls',
'done' => 'Done!',
'encode_double_error' => 'Could not properly encode double',
'extensionRecommended' => 'Warning: the %s extension is not installed, please install it to speed up MadelineProto!',
@ -736,6 +740,7 @@ If you intentionally deleted this account, ignore this message.',
'do_not_use_blocking_function' => 'for performance reasons, event handlers may not use the non-async blocking function %s, please use %s, instead',
'do_not_use_deprecated_function' => 'the %s function is deprecated, please use %s, instead',
'do_not_use_non_root_require_in_event_handler' => 'for performance reasons, you must not use require or include inside of an event handler class, only root-level requires are allowed.',
'do_not_use_yield' => 'MadelineProto 8 does not require or support the use of yield in async functions, you must remove all yield keywords previously used for async function calls',
'done' => 'בוצע!',
'encode_double_error' => 'לא ניתן היה לקודד כפול כראוי',
'extensionRecommended' => 'Warning: the %s extension is not installed, please install it to speed up MadelineProto!',
@ -899,6 +904,7 @@ Ignorare questo messaggio se la sessione è stata resettata intenzionalmente.',
'do_not_use_blocking_function' => 'per motivi di performance, gli event handler non possono usare la funzione bloccante non asincrona %s, per favore usa %s',
'do_not_use_deprecated_function' => 'la funzione %s è deprecata, per favore usa %s',
'do_not_use_non_root_require_in_event_handler' => 'per motivi di performance, non è possibile usare require o include dentro l\'event handler, è possibile includere file solo all\'esterno della classe.',
'do_not_use_yield' => 'MadelineProto 8 does not require or support the use of yield in async functions, you must remove all yield keywords previously used for async function calls',
'done' => 'Fatto!',
'encode_double_error' => 'Non sono riuscito a codificare il numero a virgola mobile fornito',
'extensionRecommended' => 'Attenzione: l\'estensione %s non è installata, si prega di installarla per velocizzare MadelineProto!',
@ -1062,6 +1068,7 @@ If you intentionally deleted this account, ignore this message.',
'do_not_use_blocking_function' => 'for performance reasons, event handlers may not use the non-async blocking function %s, please use %s, instead',
'do_not_use_deprecated_function' => 'the %s function is deprecated, please use %s, instead',
'do_not_use_non_root_require_in_event_handler' => 'for performance reasons, you must not use require or include inside of an event handler class, only root-level requires are allowed.',
'do_not_use_yield' => 'MadelineProto 8 does not require or support the use of yield in async functions, you must remove all yield keywords previously used for async function calls',
'done' => 'Готово!',
'encode_double_error' => 'Could not properly encode double',
'extensionRecommended' => 'Warning: the %s extension is not installed, please install it to speed up MadelineProto!',
@ -1225,6 +1232,7 @@ If you intentionally deleted this account, ignore this message.',
'do_not_use_blocking_function' => 'for performance reasons, event handlers may not use the non-async blocking function %s, please use %s, instead',
'do_not_use_deprecated_function' => 'the %s function is deprecated, please use %s, instead',
'do_not_use_non_root_require_in_event_handler' => 'for performance reasons, you must not use require or include inside of an event handler class, only root-level requires are allowed.',
'do_not_use_yield' => 'MadelineProto 8 does not require or support the use of yield in async functions, you must remove all yield keywords previously used for async function calls',
'done' => 'Bajarildi!',
'encode_double_error' => 'Doubleni toʻgʻri kodlab boʻlmadi',
'extensionRecommended' => 'Warning: the %s extension is not installed, please install it to speed up MadelineProto!',
@ -1390,6 +1398,7 @@ If you intentionally deleted this account, ignore this message.',
'do_not_use_blocking_function' => 'for performance reasons, event handlers may not use the non-async blocking function %s, please use %s, instead',
'do_not_use_deprecated_function' => 'the %s function is deprecated, please use %s, instead',
'do_not_use_non_root_require_in_event_handler' => 'for performance reasons, you must not use require or include inside of an event handler class, only root-level requires are allowed.',
'do_not_use_yield' => 'MadelineProto 8 does not require or support the use of yield in async functions, you must remove all yield keywords previously used for async function calls',
'done' => 'Done!',
'encode_double_error' => 'Could not properly encode double',
'extensionRecommended' => 'Warning: the %s extension is not installed, please install it to speed up MadelineProto!',

View File

@ -801,7 +801,7 @@ abstract class Tools extends AsyncTools
while ($parent = $parent->getAttribute('parent')) {
if ($parent instanceof ClassMethod
&& $parent->isPublic()
&& in_array($parent->name->toLowerString(), self::NO_YIELD_FUNCTIONS, true)
&& \in_array($parent->name->toLowerString(), self::NO_YIELD_FUNCTIONS, true)
) {
$issues []= new EventHandlerIssue(
message: Lang::$current_lang['do_not_use_yield'],