From 7098e8a2fedfd721c71564e110a77346af558ed8 Mon Sep 17 00:00:00 2001 From: "VICTOR\\anumu" Date: Tue, 24 Jan 2023 09:43:08 +0100 Subject: [PATCH] fixed contact message to return message and country to return country code --- src/component/Contact/Main.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/component/Contact/Main.js b/src/component/Contact/Main.js index 83a2190..f3f5ba5 100644 --- a/src/component/Contact/Main.js +++ b/src/component/Contact/Main.js @@ -117,7 +117,7 @@ const Main = ({ brdcum }) => { //CALLS THE API AFTER COMPONENT LOADS useEffect(() => { - allCountry().then((data) => setCountries(Object.values(data.data))); + allCountry().then((data) => setCountries(Object.keys(data.data))).catch((err)=>console.log(err.message)); }, []); // useEffect(() => { @@ -251,10 +251,10 @@ const Main = ({ brdcum }) => {