From 1d2632ca3d6d69506ff4f756a53aa5cde363cf5a Mon Sep 17 00:00:00 2001 From: GOEPP THOMAS <thomas@saturne-digital.fr> Date: Tue, 14 Jan 2025 11:11:33 +0100 Subject: [PATCH] chore: clean code --- components/lists/QuizList.tsx | 1 - screens/Multiplayer/Lobby/Lobby.tsx | 1 - .../Lobby/PlayingQuizMultiMode/PlayingQuizMultiModeBody.tsx | 5 ----- 3 files changed, 7 deletions(-) diff --git a/components/lists/QuizList.tsx b/components/lists/QuizList.tsx index dfad0f6..81051a6 100644 --- a/components/lists/QuizList.tsx +++ b/components/lists/QuizList.tsx @@ -42,7 +42,6 @@ interface Props { } export default function QuizList({ quizList, isLoadingData, nextPage, onQuizPressed }: Props) { if (quizList) { - console.log(quizList[0]); } const renderQuizItem = ({ item }: { item: Quiz }) => ( <TouchableOpacity style={styles.quizItem} onPress={() => onQuizPressed(item)}> diff --git a/screens/Multiplayer/Lobby/Lobby.tsx b/screens/Multiplayer/Lobby/Lobby.tsx index bdcdb42..fee0d0d 100644 --- a/screens/Multiplayer/Lobby/Lobby.tsx +++ b/screens/Multiplayer/Lobby/Lobby.tsx @@ -48,7 +48,6 @@ export default function Lobby({navigation, route}: Props) { }); setSocket(newSocket); - console.log(isHost); if(isHost) { newSocket.on("roomCreated", (data) => { diff --git a/screens/Multiplayer/Lobby/PlayingQuizMultiMode/PlayingQuizMultiModeBody.tsx b/screens/Multiplayer/Lobby/PlayingQuizMultiMode/PlayingQuizMultiModeBody.tsx index 1a5d713..f7cda1a 100644 --- a/screens/Multiplayer/Lobby/PlayingQuizMultiMode/PlayingQuizMultiModeBody.tsx +++ b/screens/Multiplayer/Lobby/PlayingQuizMultiMode/PlayingQuizMultiModeBody.tsx @@ -49,9 +49,6 @@ const getStyleOfAnswerButtonText = (answerId: number, selectedAnswerIndex: numbe } const getStyleOfAnswerButton = (answerId: number, selectedAnswerIndex: number | null, correctAnswerId: number | null, quizState: QuizState) => { - console.log("answerId :", answerId); - console.log("selectedAnswerIndex :", selectedAnswerIndex); - console.log("correctAnswerId :", correctAnswerId); if(quizState === QuizState.LOADING) { return styles.loadingAnswer; @@ -77,10 +74,8 @@ export default function PlayingQuizMultiModeBody({runId, actualQuestion, fetchAc const [isLastQuestion, setIsLastQuestion] = useState(false); const [quizInformations, setQuizInformations] = useState<QuizInformations>(); const [runInformations, setRunInformations] = useState<RunInformations>(); - const {answerQuestion, getRunsInfo, getQuizInformations} = useQuizService(); const getCorrectAnswer = (answers: Answer[]): Answer => { - console.log("starting getCorrectAnswer"); const correctAnswer = answers.find((answer) => answer.isCorrect); if (!correctAnswer) return answers[0]; return correctAnswer; -- GitLab