Skip to content

Commit

Permalink
fix: installed packages fail to deploy
Browse files Browse the repository at this point in the history
  • Loading branch information
Codeneos committed Aug 15, 2024
1 parent 65ceb04 commit a198601
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions packages/salesforce/src/retrieveDeltaStrategy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import { RetrieveManifestOptions, SalesforceDeployService } from "./salesforceDe
import { SalesforcePackage, SalesforcePackageComponent } from "./deploymentPackage";
import { MetadataRegistry, MetadataType } from "./metadataRegistry";
import { RetrieveResultComponent } from "./deploy";
import { outputFile } from "fs-extra";

/**
* Interface for a strategy to determine if two objects are equal. Used in the delta strategy to determine if a component has changed.
Expand Down Expand Up @@ -203,9 +202,9 @@ export class RetrieveDeltaStrategy {
});
}

private isPackageNewer(a: Buffer | string, b: Buffer | string): boolean {
const localMeta = XML.parse(a, { arrayMode: false, ignoreAttributes: true });
const orgMeta = XML.parse(b, { arrayMode: false, ignoreAttributes: true });
private isPackageNewer(current: Buffer | string, target: Buffer | string): boolean {
const localMeta = XML.parse(target, { arrayMode: false, ignoreAttributes: true });
const orgMeta = XML.parse(current, { arrayMode: false, ignoreAttributes: true });

const localVersion = parseFloat(localMeta.InstalledPackage?.versionNumber);
const orgVersion = parseFloat(orgMeta.InstalledPackage?.versionNumber);
Expand Down

0 comments on commit a198601

Please sign in to comment.