mirror of
https://github.com/alvierahman90/capitals_quiz.git
synced 2024-11-23 17:59:55 +00:00
bug fix
This commit is contained in:
parent
8b2695f241
commit
b2f37589ec
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;
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user