style: fix linting issues met Prettier
This commit is contained in:
		
							parent
							
								
									c7155fb438
								
							
						
					
					
						commit
						1dce9c65c6
					
				
					 3 changed files with 13 additions and 13 deletions
				
			
		|  | @ -23,8 +23,8 @@ import { GroupDTO } from '@dwengo-1/common/interfaces/group'; | |||
| import { SubmissionDTO, SubmissionDTOId } from '@dwengo-1/common/interfaces/submission'; | ||||
| import { QuestionDTO, QuestionId } from '@dwengo-1/common/interfaces/question'; | ||||
| import { ClassJoinRequestDTO } from '@dwengo-1/common/interfaces/class-join-request'; | ||||
| import {BadRequestException} from "../exceptions/bad-request-exception"; | ||||
| import {ConflictException} from "../exceptions/conflict-exception"; | ||||
| import { BadRequestException } from '../exceptions/bad-request-exception'; | ||||
| import { ConflictException } from '../exceptions/conflict-exception'; | ||||
| 
 | ||||
| export async function getAllStudents(full: boolean): Promise<StudentDTO[] | string[]> { | ||||
|     const studentRepository = getStudentRepository(); | ||||
|  | @ -138,7 +138,7 @@ export async function createClassJoinRequest(username: string, classId: string): | |||
|     const cls = await fetchClass(classId); | ||||
| 
 | ||||
|     if (cls.students.contains(student)) { | ||||
|         throw new ConflictException("Student already in this class"); | ||||
|         throw new ConflictException('Student already in this class'); | ||||
|     } | ||||
| 
 | ||||
|     const request = mapToStudentRequest(student, cls); | ||||
|  |  | |||
|  | @ -22,15 +22,15 @@ import { Question } from '../entities/questions/question.entity.js'; | |||
| import { ClassJoinRequestRepository } from '../data/classes/class-join-request-repository.js'; | ||||
| import { Student } from '../entities/users/student.entity.js'; | ||||
| import { NotFoundException } from '../exceptions/not-found-exception.js'; | ||||
| import {addClassStudent, fetchClass, getClassStudents, getClassStudentsDTO} from './classes.js'; | ||||
| import { addClassStudent, fetchClass, getClassStudents, getClassStudentsDTO } from './classes.js'; | ||||
| import { TeacherDTO } from '@dwengo-1/common/interfaces/teacher'; | ||||
| import { ClassDTO } from '@dwengo-1/common/interfaces/class'; | ||||
| import { StudentDTO } from '@dwengo-1/common/interfaces/student'; | ||||
| import { QuestionDTO, QuestionId } from '@dwengo-1/common/interfaces/question'; | ||||
| import { ClassJoinRequestDTO } from '@dwengo-1/common/interfaces/class-join-request'; | ||||
| import { ClassJoinRequestStatus } from '@dwengo-1/common/util/class-join-request'; | ||||
| import {BadRequestException} from "../exceptions/bad-request-exception"; | ||||
| import {ConflictException} from "../exceptions/conflict-exception"; | ||||
| import { BadRequestException } from '../exceptions/bad-request-exception'; | ||||
| import { ConflictException } from '../exceptions/conflict-exception'; | ||||
| 
 | ||||
| export async function getAllTeachers(full: boolean): Promise<TeacherDTO[] | string[]> { | ||||
|     const teacherRepository: TeacherRepository = getTeacherRepository(); | ||||
|  | @ -152,7 +152,7 @@ export async function updateClassJoinRequestStatus(studentUsername: string, clas | |||
|     const cls = await fetchClass(classId); | ||||
| 
 | ||||
|     if (cls.students.contains(student)) { | ||||
|         throw new ConflictException("Student already in this class"); | ||||
|         throw new ConflictException('Student already in this class'); | ||||
|     } | ||||
| 
 | ||||
|     const request: ClassJoinRequest | null = await requestRepo.findByStudentAndClass(student, cls); | ||||
|  | @ -163,7 +163,7 @@ export async function updateClassJoinRequestStatus(studentUsername: string, clas | |||
| 
 | ||||
|     request.status = ClassJoinRequestStatus.Declined; | ||||
| 
 | ||||
|     if (accepted){ | ||||
|     if (accepted) { | ||||
|         request.status = ClassJoinRequestStatus.Accepted; | ||||
|         await addClassStudent(classId, studentUsername); | ||||
|     } | ||||
|  |  | |||
		Reference in a new issue
	
	 Lint Action
						Lint Action