diff --git a/app/src/main/java/com/github/catvod/bean/alist/Item.java b/app/src/main/java/com/github/catvod/bean/alist/Item.java index 9eba79e6..1e542e5e 100644 --- a/app/src/main/java/com/github/catvod/bean/alist/Item.java +++ b/app/src/main/java/com/github/catvod/bean/alist/Item.java @@ -35,14 +35,6 @@ public class Item { return new Gson().fromJson(str, Item.class); } - public static Item playList(Item copy, String vodPic) { - Item item = new Item(); - item.name = "播放列表"; - item.path = copy.path; - item.thumb = vodPic; - return item; - } - public static List arrayFrom(String str) { Type listType = new TypeToken>() {}.getType(); return new Gson().fromJson(str, listType); diff --git a/app/src/main/java/com/github/catvod/spider/AList.java b/app/src/main/java/com/github/catvod/spider/AList.java index c21f4dc3..e6d244aa 100644 --- a/app/src/main/java/com/github/catvod/spider/AList.java +++ b/app/src/main/java/com/github/catvod/spider/AList.java @@ -87,7 +87,6 @@ public class AList extends Spider { fetchRule(); String type = extend.containsKey("type") ? extend.get("type") : ""; String order = extend.containsKey("order") ? extend.get("order") : ""; - String key = tid.contains("/") ? tid.substring(0, tid.indexOf("/")) : tid; List folders = new ArrayList<>(); List files = new ArrayList<>(); List list = new ArrayList<>(); @@ -101,11 +100,6 @@ public class AList extends Spider { Sorter.sort(type, order, files); } - int count = 0; - Drive drive = getDrive(key); - for (Item item : files) if (item.isMedia(drive.isNew())) count++; - if (count > 1) folders.add(0, Item.playList(files.get(0), vodPic)); - for (Item item : folders) list.add(item.getVod(tid, vodPic)); for (Item item : files) list.add(item.getVod(tid, vodPic)); return Result.get().vod(list).page().string(); @@ -115,7 +109,6 @@ public class AList extends Spider { public String detailContent(List ids) throws Exception { fetchRule(); String id = ids.get(0); - boolean list = id.endsWith("播放列表"); String key = id.contains("/") ? id.substring(0, id.indexOf("/")) : id; String path = id.substring(0, id.lastIndexOf("/")); String name = path.substring(path.lastIndexOf("/") + 1); @@ -124,22 +117,12 @@ public class AList extends Spider { Sorter.sort("name", "asc", parents); Vod vod = new Vod(); vod.setVodPlayFrom(key); - - if (list) { - vod.setVodId(id); - vod.setVodName(name); - vod.setVodPic(vodPic); - List playUrls = new ArrayList<>(); - for (Item item : parents) if (item.isMedia(drive.isNew())) playUrls.add(item.getName() + "$" + item.getVodId(path) + findSubs(path, parents)); - vod.setVodPlayUrl(TextUtils.join("#", playUrls)); - } else { - Item item = getDetail(id); - vod.setVodId(item.getVodId(id)); - vod.setVodName(item.getName()); - vod.setVodPic(item.getPic(vodPic)); - vod.setVodPlayUrl(item.getName() + "$" + item.getVodId(path) + findSubs(path, parents)); - } - + vod.setVodId(id); + vod.setVodName(name); + vod.setVodPic(vodPic); + List playUrls = new ArrayList<>(); + for (Item item : parents) if (item.isMedia(drive.isNew())) playUrls.add(item.getName() + "$" + item.getVodId(path) + findSubs(path, parents)); + vod.setVodPlayUrl(TextUtils.join("#", playUrls)); return Result.string(vod); } diff --git a/jar/custom_spider.jar b/jar/custom_spider.jar index 24e39341..2264fc93 100644 Binary files a/jar/custom_spider.jar and b/jar/custom_spider.jar differ diff --git a/jar/custom_spider.jar.md5 b/jar/custom_spider.jar.md5 index 4a4a7dee..dd70397e 100644 --- a/jar/custom_spider.jar.md5 +++ b/jar/custom_spider.jar.md5 @@ -1 +1 @@ -ae1463f4584754ef50ab902920ccb7da +942e99b122cf9eb8d0859bbab9994f12