修复FastJSON大版本更新后API变动
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
package com.yutou.qqbot.models.Commands;
|
||||
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.alibaba.fastjson2.JSON;
|
||||
import com.alibaba.fastjson2.JSONObject;
|
||||
import com.yutou.qqbot.QQBotManager;
|
||||
import com.yutou.qqbot.interfaces.DownloadInterface;
|
||||
import com.yutou.qqbot.models.Model;
|
||||
@@ -48,7 +49,7 @@ public class Moyu extends Model {
|
||||
|
||||
private void downloadImage() {
|
||||
String ret = HttpTools.get("https://api.j4u.ink/proxy/remote/moyu.json");
|
||||
JSONObject json = JSONObject.parseObject(ret);
|
||||
JSONObject json = JSON.parseObject(ret);
|
||||
HttpTools.download(json.getJSONObject("data").getString("moyu_url"), AppTools.getToDayTime() + "_moyu.jpg", new DownloadInterface() {
|
||||
@Override
|
||||
public void onDownload(File file) {
|
||||
|
||||
Reference in New Issue
Block a user