Skip to content

Commit

Permalink
fix lint
Browse files Browse the repository at this point in the history
  • Loading branch information
christinaroise committed Sep 3, 2024
1 parent bd82336 commit 0099991
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions studio/schemas/documents/compensations.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,15 +50,15 @@ const compensations = defineType({
*/
...[...Array(LOCATIONS_PREVIEW_CUTOFF + 1).keys()].reduce(
(o, i) => ({ ...o, [`location${i}`]: `locations.${i}.basicTitle` }),
{}
{},
),
},
prepare({ title, ...locationsMap }) {
return {
title,
subtitle: previewStringFromLocationsMap(
locationsMap,
LOCATIONS_PREVIEW_CUTOFF
LOCATIONS_PREVIEW_CUTOFF,
),
};
},
Expand All @@ -76,10 +76,10 @@ function previewStringFromLocationsMap(
locationsMap: {
[key: string]: string;
},
cutoff: number
cutoff: number,
): string | undefined {
const locations = Object.values<string>(locationsMap).filter(
(o) => o !== undefined
(o) => o !== undefined,
);
if (locations.length === 0) {
return undefined;
Expand Down

0 comments on commit 0099991

Please sign in to comment.