Skip to content

Commit

Permalink
Obsolete removed PackageState.Cached value
Browse files Browse the repository at this point in the history
A package's cached status is no longer set via the PackageState. The value was
removed in native code but the managed code was missed throwing off the enum
mapping.

Fixes 7399
  • Loading branch information
robmen committed May 30, 2023
1 parent 0215995 commit bc9343a
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
11 changes: 6 additions & 5 deletions src/api/burn/WixToolset.Mba.Core/IBootstrapperEngine.cs
Expand Up @@ -407,11 +407,6 @@ public enum PackageState
/// </summary>
Absent,

/// <summary>
/// The package is not installed but is in the package cache.
/// </summary>
Cached,

/// <summary>
/// The package is installed.
/// </summary>
Expand All @@ -421,6 +416,12 @@ public enum PackageState
/// The package is on the machine but not active, so only uninstall operations are allowed.
/// </summary>
Superseded,

/// <summary>
/// This value is no longer used. See the DetectPackageCompleteEventArgs.Cached value instead.
/// </summary>
[Obsolete("Use DetectPackageCompleteEventArgs.Cached instead.")]
Cached = Present,
}

/// <summary>
Expand Down
2 changes: 1 addition & 1 deletion src/test/burn/TestBA/TestBA.cs
Expand Up @@ -299,7 +299,7 @@ protected override void OnPlanPackageBegin(PlanPackageBeginEventArgs args)
args.CacheType = cacheType;
}

this.Log("OnPlanPackageBegin() - id: {0}, defaultState: {1}, requestedState: {2}, defaultCache: {3}, requestedCache: {4}", args.PackageId, args.RecommendedState, args.State, args.RecommendedCacheType, args.CacheType);
this.Log("OnPlanPackageBegin() - id: {0}, currentState: {1}, defaultState: {2}, requestedState: {3}, defaultCache: {4}, requestedCache: {5}", args.PackageId, args.CurrentState, args.RecommendedState, args.State, args.RecommendedCacheType, args.CacheType);
}

protected override void OnPlanPatchTarget(PlanPatchTargetEventArgs args)
Expand Down

0 comments on commit bc9343a

Please sign in to comment.