clean up
This commit is contained in:
@@ -1,9 +1,6 @@
|
||||
import { HttpException, HttpStatus, Injectable } from '@nestjs/common';
|
||||
import { InjectRepository } from '@nestjs/typeorm';
|
||||
import { User } from 'src/users/entities/user.entity';
|
||||
|
||||
import { SendableUser } from 'src/users/sendableUsers';
|
||||
|
||||
import { Repository, Brackets } from 'typeorm';
|
||||
import { CreateFriendshipDto } from './dto/create-friendship.dto';
|
||||
import { Friendship, FriendshipStatus } from './entities/friendship.entity';
|
||||
@@ -77,7 +74,6 @@ export class FriendshipService {
|
||||
)
|
||||
}),
|
||||
)
|
||||
// .andWhere('friendship.status != :status', {status : FriendshipStatus.BLOCKED})
|
||||
.getOne()
|
||||
|
||||
// console.log('END Find one friend by username: ')
|
||||
@@ -85,8 +81,6 @@ export class FriendshipService {
|
||||
|
||||
if (!friendship) {
|
||||
throw new HttpException(`There is no such friendship`, HttpStatus.NOT_FOUND);
|
||||
// throw new HttpException(`There is no such friendship`, HttpStatus.NO_CONTENT);
|
||||
// throw new HttpException(`There is no such friendship`, 204);
|
||||
}
|
||||
return new SendableFriendship(friendship);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user