Skip to content

Commit

Permalink
update to urlField
Browse files Browse the repository at this point in the history
  • Loading branch information
MohammadPCh committed Jun 6, 2024
1 parent 1f77007 commit 2b2f0e2
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
8 changes: 4 additions & 4 deletions src/features/import-projects/helpers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export const updateOrCreateProject = async (
idField,
titleField,
descriptionField,
slugField,
urlField,
imageField,
} = sourConfig;

Expand All @@ -36,7 +36,7 @@ export const updateOrCreateProject = async (
const isUpdated =
existingProject.title !== project[titleField] ||
existingProject.description !== project[descriptionField] ||
existingProject.url !== project[slugField] ||
existingProject.url !== project[urlField] ||
existingProject.image !== project[imageField];

if (isUpdated) {
Expand All @@ -45,7 +45,7 @@ export const updateOrCreateProject = async (
title: project[titleField],
description: project[descriptionField],
image: project[imageField],
url: project[slugField],
url: project[urlField],
lastUpdatedTimestamp: new Date(),
imported: true,
});
Expand All @@ -67,7 +67,7 @@ export const updateOrCreateProject = async (
title: project[titleField],
description: project[descriptionField],
image: project[imageField],
url: project[slugField],
url: project[urlField],
projectId: projectId,
source: source,
totalVouches: 0,
Expand Down
2 changes: 1 addition & 1 deletion src/features/import-projects/rpgf/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@ export const rpgf3SourceConfig: SourceConfig = {
idField: "RPGF3Id",
titleField: "name",
descriptionField: "impactDescription",
slugField: "url",
urlField: "url",
imageField: "image",
};
2 changes: 1 addition & 1 deletion src/features/import-projects/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@ interface SourceConfig {
idField: string;
titleField: string;
descriptionField: string;
slugField: string;
urlField: string;
imageField: string;
}

0 comments on commit 2b2f0e2

Please sign in to comment.