Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
xjbeta committed Jun 6, 2024
2 parents b08a154 + b45547b commit 375a732
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 3 deletions.
4 changes: 2 additions & 2 deletions IINA+.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -1041,7 +1041,7 @@
"@executable_path/../Frameworks",
);
MACOSX_DEPLOYMENT_TARGET = 10.14;
MARKETING_VERSION = 0.7.29;
MARKETING_VERSION = 0.7.30;
PRODUCT_BUNDLE_IDENTIFIER = "com.xjbeta.iina-plus";
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
Expand All @@ -1068,7 +1068,7 @@
"@executable_path/../Frameworks",
);
MACOSX_DEPLOYMENT_TARGET = 10.14;
MARKETING_VERSION = 0.7.29;
MARKETING_VERSION = 0.7.30;
PRODUCT_BUNDLE_IDENTIFIER = "com.xjbeta.iina-plus";
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
Expand Down
12 changes: 11 additions & 1 deletion IINA+/Utils/VideoDecoder/Huya.swift
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,17 @@ class Huya: NSObject, SupportSiteProtocol {
}
let rid = ucs[2]

return pSession.request("https://mp.huya.com/cache.php?m=Live&do=profileRoom&roomid=\(rid)").responseData().map {
if let rid = Int(rid) {
return getHuyaInfoMP(rid)
} else {
return getHuyaInfo(url).then {
self.getHuyaInfoMP($0.rid)
}
}
}

func getHuyaInfoMP(_ rid: Int) -> Promise<HuyaInfoMP> {
pSession.request("https://mp.huya.com/cache.php?m=Live&do=profileRoom&roomid=\(rid)").responseData().map {
let jsonObj: JSONObject = try JSONParser.JSONObjectWithData($0.data)
return try HuyaInfoMP(object: jsonObj)
}
Expand Down

0 comments on commit 375a732

Please sign in to comment.