Added release date support to Codeberg

This commit is contained in:
Imran Remtulla
2023-02-18 20:58:08 -05:00
parent f06d245e20
commit d5fdf28a98

View File

@ -112,11 +112,15 @@ class Codeberg extends AppSource {
throw NoReleasesError();
}
String? version = targetRelease['tag_name'];
DateTime? releaseDate = targetRelease['published_at'] != null
? DateTime.parse(targetRelease['published_at'])
: null;
if (version == null) {
throw NoVersionError();
}
return APKDetails(version, targetRelease['apkUrls'] as List<String>,
getAppNames(standardUrl));
getAppNames(standardUrl),
releaseDate: releaseDate);
} else {
throw getObtainiumHttpError(res);
}