Skip to content

Commit

Permalink
[DX-1781] - removed consoles
Browse files Browse the repository at this point in the history
  • Loading branch information
naman-contentstack committed Dec 9, 2024
1 parent 68d64b0 commit 4153ecf
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 8 deletions.
4 changes: 0 additions & 4 deletions packages/contentstack-variants/src/import/experiences.ts
Original file line number Diff line number Diff line change
Expand Up @@ -239,9 +239,6 @@ export default class Experiences extends PersonalizationAdapter<ImportConfig> {
const promises = this.pendingVariantAndVariantGrpForExperience.map(async (expUid) => {
const expRes = await this.getExperience(expUid);
if (expRes?._cms && expRes?._cms?.variantGroup && Object.keys(expRes._cms.variants).length > 0) {
console.log('πŸš€ ~ Experiences ~ promises ~ expRes:Variant', expRes._cms.variants);
console.log('πŸš€ ~ Experiences ~ promises ~ expRes:Group', expRes._cms.variantGroup);

this.cmsVariants[expUid] = expRes._cms?.variants ?? {};
this.cmsVariantGroups[expUid] = expRes._cms?.variantGroup ?? {};
return expUid; // Return the expUid for filtering later
Expand Down Expand Up @@ -311,7 +308,6 @@ export default class Experiences extends PersonalizationAdapter<ImportConfig> {
for (let experienceVariantId of experienceVariantIds) {
const [experienceId, variantShortId, oldVariantId] = experienceVariantId.split('-');
const latestVariantId = this.cmsVariants[this.experiencesUidMapper[experienceId]]?.[variantShortId];
console.log('πŸš€ ~ Experiences ~ createVariantIdMapper ~ this.experiencesUidMapper:', this.experiencesUidMapper);
if (latestVariantId) {
variantUIDMapper[oldVariantId] = latestVariantId;
}
Expand Down
4 changes: 0 additions & 4 deletions packages/contentstack-variants/src/import/variant-entries.ts
Original file line number Diff line number Diff line change
Expand Up @@ -195,13 +195,11 @@ export default class VariantEntries extends VariantAdapter<VariantHttpClient<Imp
variantEntries: VariantEntryStruct[],
entriesForVariant: EntryDataForVariantEntries,
) {
console.log('πŸš€ ~ variantEntries:', variantEntries);
let batchNo = 0;
const variantEntryConfig = this.config.modules.variantEntry;
const { content_type, locale, entry_uid } = entriesForVariant;
const entryUid = this.entriesUidMapper[entry_uid];
const batches = chunk(variantEntries, variantEntryConfig.apiConcurrency || 5);
console.log('πŸš€ ~ batches:', batches);

if (isEmpty(batches)) return;

Expand Down Expand Up @@ -231,8 +229,6 @@ export default class VariantEntries extends VariantAdapter<VariantHttpClient<Imp
};
// NOTE Find new variant Id by old Id
const variantId = this.variantIdList[variantEntry._variant._uid] as string;
console.log('πŸš€ ~ this.variantIdList:', this.variantIdList);
console.log('πŸš€ ~ variantId:', variantId);
// NOTE Replace all the relation data UID's
variantEntry = this.handleVariantEntryRelationalData(contentType, variantEntry);
const changeSet = this.serializeChangeSet(variantEntry);
Expand Down

0 comments on commit 4153ecf

Please sign in to comment.