mirror of
https://github.com/alvierahman90/capitals_quiz.git
synced 2025-10-13 07:54:27 +00:00
bug fix
This commit is contained in:
4
game.js
4
game.js
@@ -47,13 +47,13 @@ const getMasterQuestionList = () => {
|
|||||||
};
|
};
|
||||||
|
|
||||||
const getQuestionByCountryName = (name) => {
|
const getQuestionByCountryName = (name) => {
|
||||||
c = getMasterQuestionList().filter((c) => c.countryname === name);
|
var c = getMasterQuestionList().filter((c) => c.countryname === name);
|
||||||
if (c.length > 0) return c[0];
|
if (c.length > 0) return c[0];
|
||||||
return null;
|
return null;
|
||||||
};
|
};
|
||||||
|
|
||||||
const getQuestionByCapital = (capital) => {
|
const getQuestionByCapital = (capital) => {
|
||||||
c = getMasterQuestionList().filter((c) => c.capital === capital);
|
var c = getMasterQuestionList().filter((c) => c.capital === capital);
|
||||||
if (c.length > 0) return c[0];
|
if (c.length > 0) return c[0];
|
||||||
return null;
|
return null;
|
||||||
};
|
};
|
||||||
|
Reference in New Issue
Block a user