koishi-plugin-minecraft-notifier 1.8.0 → 1.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/index.cjs +7 -1
- package/package.json +1 -1
package/lib/index.cjs
CHANGED
|
@@ -1134,10 +1134,16 @@ function apply(ctx, cfg) {
|
|
|
1134
1134
|
koaCtx.response.body = await import_node_fs2.promises.readFile(fullHomePagePath);
|
|
1135
1135
|
});
|
|
1136
1136
|
ctx.server.get("/Custom.xaml.ini", async (koaCtx) => {
|
|
1137
|
-
koaCtx.set("charset=utf-8");
|
|
1137
|
+
koaCtx.set("Content-Type: text/plain; charset=utf-8");
|
|
1138
1138
|
const articleRecord = (await ctx.database.get("minecraft_article_version", 1))[0];
|
|
1139
1139
|
koaCtx.response.body = articleRecord.latestVersion;
|
|
1140
1140
|
});
|
|
1141
|
+
ctx.server.get("/Custom.json", async (koaCtx) => {
|
|
1142
|
+
koaCtx.set("Content-Type", "application/json; charset=utf-8");
|
|
1143
|
+
koaCtx.response.body = JSON.stringify({
|
|
1144
|
+
Title: "Minecraft \u66F4\u65B0\u6458\u8981"
|
|
1145
|
+
});
|
|
1146
|
+
});
|
|
1141
1147
|
ctx.command("mc.trigger", "\u624B\u52A8\u89E6\u53D1 AI \u66F4\u65B0\u65E5\u5FD7\u603B\u7ED3\u751F\u6210", {
|
|
1142
1148
|
authority: 4
|
|
1143
1149
|
}).action(async () => {
|
package/package.json
CHANGED