Skip to content
This repository was archived by the owner on Aug 16, 2024. It is now read-only.

Commit ad84023

Browse files
committed
更新: examples/RepeatMessage.cpp;
1 parent 2a8e823 commit ad84023

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

examples/RepeatMessage.cpp

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -19,15 +19,15 @@ int main()
1919
// 检查一下版本
2020
try
2121
{
22-
// 获取 mirai-api-http 插件地版本
23-
string current_version = bot.GetApiVersion();
24-
// 获取 mirai-cpp 适配的版本
25-
string required_version = bot.GetRequiredApiVersion();
26-
cout << "! 需要的 API 版本: " << required_version
27-
<< "; 当前 API 版本: " << current_version << "; " << endl;
28-
if (current_version != required_version)
22+
// 获取 mirai-api-http 插件的版本
23+
string mah_version = bot.GetMiraiApiHttpVersion();
24+
// 获取 mirai-cpp 的版本
25+
string mc_version = bot.GetMiraiCppVersion();
26+
cout << "! mirai-api-http 的版本: " << mah_version
27+
<< "; 当mirai-cpp 的版本: " << mc_version << "; " << endl;
28+
if (mah_version != mc_version)
2929
{
30-
cout << "! 警告: 你的 mirai-api-http 插件的版本与 mirai-cpp 适配的版本不同,可能存在潜在的异常" << endl;
30+
cout << "! 警告: 你的 mirai-api-http 插件的版本与 mirai-cpp 的版本不同,可能存在兼容性问题" << endl;
3131
}
3232
}
3333
catch (const std::exception& ex)

0 commit comments

Comments
 (0)