Fix upcoming assignments mock fetching

This commit is contained in:
Leonardo Murça 2022-09-17 15:32:06 -03:00
parent eac9146d58
commit af37f8a863
2 changed files with 3 additions and 3 deletions

View file

@ -144,7 +144,7 @@ const allAssignments = [
classrooms: allClassrooms.filter(c => c.id === '666'),
},
{
id: '1234',
id: '9283764',
type: 'assessment',
title: 'Atividade 2 - Estudo de caso Sapiens Informática',
description:

View file

@ -38,8 +38,8 @@ const getUpcomingAssignmentsByClassId = classId =>
sleep(300).then(() => {
console.log('Getting upcoming assignments by class id ' + classId);
return {
data: allUpcomingAssignments.filter(a =>
a.classrooms.filter(c => c.id === classId)
data: allUpcomingAssignments.filter(
a => a.classrooms.filter(c => c.id === classId)[0]
),
};
});