Skip to content

Commit bb5db23

Browse files
committed
fix(wpcheck): fix wpCheck data handling
1 parent 5de55f3 commit bb5db23

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

src/components/Markers.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -191,7 +191,7 @@ const Markers: React.FC<MarkersPropsType> = ({
191191
</li>
192192
<li className="flex gap-2">
193193
<h3 className="font-semibold">HAS WP</h3>
194-
{!hasWp ? (
194+
{isWpCheckLoading ? (
195195
<NotAvailableMarker loading={isWpCheckLoading} />
196196
) : (
197197
<span

src/services/wpCheck.service.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ export const isWordpressInstalled = async (domain: string) => {
1111
}
1212
);
1313

14-
return response.data;
14+
return response.data.data;
1515
} catch (error) {
1616
console.error(error);
1717
}

src/views/Results.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ const Results = () => {
7878
setHasWwwRecord(answer);
7979
}),
8080
isWordpressInstalled(domain).then(data => {
81-
setHasWp(data.isInstalled);
81+
setHasWp(data.wordpressInstalled);
8282
setIsWpCheckLoading(false);
8383
}),
8484
isCdnActive(domain).then(data => {

0 commit comments

Comments
 (0)