AoiTelegram@0.4.0
Added
- Partial support for Telegram API
7.0
added. functionError
event added to the command loader.CustomEvent
class introduced for creating custom events based onEventEmitter
.<LoadCommands>.loadVariables
method added to load variables from a folder.- Added chat/user ID verification (partial implementation).
- Added support for
suppressErrors
($suppressErrors
) in case of code errors (If set totrue
in options forsendMessageError
andfunctionError
,suppressErrors
will override them).
Fixes
- Typing of parameters in the
<AoiClient>.addFunction
method and internal library classes corrected. - Support for
@aoitelegram/database
fixed; code forTimeout
was dependent ondatabase-sempai
, which was not initially addressed, and support for the new DB should be present. - Fixed
sendMessageError
option in theAoiClient
class constructor. <Context>.getAoiArgs
method incorrectly returned theinside
parameter.- Parsing of objects in the
<Context>.evaluateArgs
method fixed.
Updated
- Comments for the source code have been refined.
- Removed the use of
async/await
for methods in the@aoitelegram/database
library (the library uses synchronous functions). - Parameter
line
is no longer required wherever needed in theMessageError
class. - Error messages are now more user-friendly, and the text of errors in
<Context>.checkArgumentTypes
has been reduced. - Changed the function loading from the library. Previously, functions were loaded when using commands/events, which took some time. Now, all functions will be loaded at the bot's start, significantly speeding up code execution when using commands/events.
AoiTelegram Function
- Numerous functions fixed, and several functions added. Only
$toString
and$availableParallelism
were removed. - Readability improved for external functions.