mirror of
https://github.com/revanced/revanced-api.git
synced 2025-05-02 07:34:29 +02:00
Rename field
This commit is contained in:
parent
df32531770
commit
d9c6e521a6
@ -50,11 +50,11 @@ class APIAsset(
|
|||||||
val downloadUrl: String,
|
val downloadUrl: String,
|
||||||
val signatureDownloadUrl: String,
|
val signatureDownloadUrl: String,
|
||||||
// TODO: Remove this eventually when integrations are merged into patches.
|
// TODO: Remove this eventually when integrations are merged into patches.
|
||||||
val type: APIAssetType,
|
val name: APIAssetName,
|
||||||
)
|
)
|
||||||
|
|
||||||
@Serializable
|
@Serializable
|
||||||
enum class APIAssetType {
|
enum class APIAssetName {
|
||||||
PATCHES,
|
PATCHES,
|
||||||
INTEGRATION,
|
INTEGRATION,
|
||||||
}
|
}
|
||||||
|
@ -31,20 +31,20 @@ internal class PatchesService(
|
|||||||
|
|
||||||
fun ConfigurationRepository.AssetConfiguration.asset(
|
fun ConfigurationRepository.AssetConfiguration.asset(
|
||||||
release: BackendRepository.BackendOrganization.BackendRepository.BackendRelease,
|
release: BackendRepository.BackendOrganization.BackendRepository.BackendRelease,
|
||||||
assetType: APIAssetType,
|
assetName: APIAssetName,
|
||||||
) = APIAsset(
|
) = APIAsset(
|
||||||
release.assets.first(assetRegex).downloadUrl,
|
release.assets.first(assetRegex).downloadUrl,
|
||||||
release.assets.first(signatureAssetRegex).downloadUrl,
|
release.assets.first(signatureAssetRegex).downloadUrl,
|
||||||
assetType,
|
assetName,
|
||||||
)
|
)
|
||||||
|
|
||||||
val patchesAsset = configurationRepository.patches.asset(
|
val patchesAsset = configurationRepository.patches.asset(
|
||||||
patchesRelease,
|
patchesRelease,
|
||||||
APIAssetType.PATCHES,
|
APIAssetName.PATCHES,
|
||||||
)
|
)
|
||||||
val integrationsAsset = configurationRepository.integrations.asset(
|
val integrationsAsset = configurationRepository.integrations.asset(
|
||||||
integrationsRelease,
|
integrationsRelease,
|
||||||
APIAssetType.INTEGRATION,
|
APIAssetName.INTEGRATION,
|
||||||
)
|
)
|
||||||
|
|
||||||
return APIRelease(
|
return APIRelease(
|
||||||
|
Loading…
x
Reference in New Issue
Block a user