diff --git a/components/insight/InsightStats.tsx b/components/insight/InsightStats.tsx index 225f97e..ed047fb 100644 --- a/components/insight/InsightStats.tsx +++ b/components/insight/InsightStats.tsx @@ -21,10 +21,10 @@ const InsightStats = ({ stats = [], totalKeywords = 0, totalPages = 0 }:InsightS position: item.position + acc.position, }; }, { impressions: 0, clicks: 0, position: 0 }); - + return { ...totals, - ctr: totals.impressions > 0 ? (totals.clicks / totals.impressions) * 100 : 0 + ctr: totals.impressions > 0 ? (totals.clicks / totals.impressions) * 100 : 0, }; }, [stats]); diff --git a/components/keywords/Keyword.tsx b/components/keywords/Keyword.tsx index 2dec794..23eb89c 100644 --- a/components/keywords/Keyword.tsx +++ b/components/keywords/Keyword.tsx @@ -73,7 +73,7 @@ const Keyword = (props: KeywordProps) => { let bestPos; if (Object.keys(history).length > 0) { const historyArray = Object.keys(history).map((itemID) => ({ date: itemID, position: history[itemID] })) - .sort((a, b) => a.position - b.position).filter((el) => (el.position > 0));; + .sort((a, b) => a.position - b.position).filter((el) => (el.position > 0)); if (historyArray[0]) { bestPos = { ...historyArray[0] }; }