chore: removed rejectOnNotFound property from prisma query in team-enviroment method
This commit is contained in:
@@ -107,7 +107,7 @@ services:
|
||||
build:
|
||||
dockerfile: packages/hoppscotch-backend/Dockerfile
|
||||
context: .
|
||||
target: prod
|
||||
target: dev
|
||||
env_file:
|
||||
- ./.env
|
||||
restart: always
|
||||
|
||||
@@ -183,11 +183,10 @@ export class TeamEnvironmentsService {
|
||||
*/
|
||||
async createDuplicateEnvironment(id: string) {
|
||||
try {
|
||||
const environment = await this.prisma.teamEnvironment.findFirst({
|
||||
const environment = await this.prisma.teamEnvironment.findFirstOrThrow({
|
||||
where: {
|
||||
id: id,
|
||||
},
|
||||
rejectOnNotFound: true,
|
||||
});
|
||||
|
||||
const result = await this.prisma.teamEnvironment.create({
|
||||
|
||||
Reference in New Issue
Block a user