Skip to content

Commit

Permalink
fix: encode method in abstractlazilyencodablesection not returning up…
Browse files Browse the repository at this point in the history
…dated gpp string
  • Loading branch information
ankitonetrust committed Jan 24, 2025
1 parent 4ad2a1f commit 91136b8
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 0 deletions.
1 change: 1 addition & 0 deletions modules/cmpapi/src/encoder/GppModel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -242,6 +242,7 @@ export class GppModel {
let sectionName = Sections.SECTION_ORDER[i];
if (sections.has(sectionName)) {
let section = sections.get(sectionName);
section.setIsDirty(true);
encodedSections.push(section.encode());
sectionIds.push(section.getId());
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -105,4 +105,8 @@ export abstract class AbstractLazilyEncodableSection implements EncodableSection
this.dirty = false;
this.decoded = false;
}

public setIsDirty(status: boolean): any {
this.dirty = status;
}
}
2 changes: 2 additions & 0 deletions modules/cmpapi/src/encoder/section/EncodableSection.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,6 @@ export interface EncodableSection {
encode(): string;

decode(encodedString: string): void;

setIsDirty(status: boolean): any;
}

0 comments on commit 91136b8

Please sign in to comment.