This commit is contained in:
Andrey Dubov 2020-08-14 14:19:34 +03:00 коммит произвёл GitHub
Родитель 2aafd8a123
Коммит 4a1539f99f
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 4AEE18F83AFDEB23
2 изменённых файлов: 12 добавлений и 8 удалений

Просмотреть файл

@ -297,7 +297,7 @@ class AccountManager {
const appParams = await this._adapter.parseApiAppName(appName);
const requestBody = targetRelease ? {
label: targetRelease
} : null;
} : {};
await this._requestManager.post(urlEncode`/apps/${appParams.appOwner}/${appParams.appName}/deployments/${deploymentName}/rollback_release`, JSON.stringify(requestBody), /*expectResponseBody=*/ false);
return null;

Просмотреть файл

@ -271,13 +271,17 @@ class Adapter {
public toRestReleaseModification(
legacyCodePushReleaseInfo: sdkTypes.PackageInfo
): adapterTypes.ReleaseModification {
const releaseModification: adapterTypes.ReleaseModification = {
target_binary_range: legacyCodePushReleaseInfo.appVersion,
is_disabled: legacyCodePushReleaseInfo.isDisabled,
is_mandatory: legacyCodePushReleaseInfo.isMandatory,
description: legacyCodePushReleaseInfo.description,
rollout: legacyCodePushReleaseInfo.rollout
};
let releaseModification: adapterTypes.ReleaseModification = {} as adapterTypes.ReleaseModification ;
if (legacyCodePushReleaseInfo.appVersion) releaseModification.target_binary_range = legacyCodePushReleaseInfo.appVersion;
if (legacyCodePushReleaseInfo.isDisabled) releaseModification.is_disabled = legacyCodePushReleaseInfo.isDisabled;
if (legacyCodePushReleaseInfo.isMandatory) releaseModification.is_mandatory = legacyCodePushReleaseInfo.isMandatory;
if (legacyCodePushReleaseInfo.description) releaseModification.description = legacyCodePushReleaseInfo.description;
if (legacyCodePushReleaseInfo.rollout) releaseModification.rollout = legacyCodePushReleaseInfo.rollout;
if (legacyCodePushReleaseInfo.label) releaseModification.label = legacyCodePushReleaseInfo.label;