Refactor most getServerProps to fetch independent request in parallel and projected the data only to return the necessary fields and changed some functions
This commit is contained in:
@@ -1,11 +1,8 @@
|
||||
import { collection, getDocs, query, where, setDoc, doc, Firestore, getDoc, and } from "firebase/firestore";
|
||||
import { groupBy, shuffle } from "lodash";
|
||||
import { CEFRLevels, Difficulty, Exam, InstructorGender, SpeakingExam, Variant, WritingExam } from "@/interfaces/exam";
|
||||
import { CEFRLevels, Exam, InstructorGender, SpeakingExam, Variant, WritingExam } from "@/interfaces/exam";
|
||||
import { DeveloperUser, Stat, StudentUser, User } from "@/interfaces/user";
|
||||
import { Module } from "@/interfaces";
|
||||
import { getCorporateUser } from "@/resources/user";
|
||||
import { getUserCorporate } from "./groups.be";
|
||||
import { Db, ObjectId } from "mongodb";
|
||||
import { Db } from "mongodb";
|
||||
import client from "@/lib/mongodb";
|
||||
import { MODULE_ARRAY } from "./moduleUtils";
|
||||
import { mapBy } from ".";
|
||||
|
||||
Reference in New Issue
Block a user