Skip to content

Commit b5522d2

Browse files
authored
feat(backend) avoid showing project that photo url is null (#195)
<!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **New Features** - Updated public projects listing to display only projects that include a photo, ensuring a visually consistent experience for users. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
1 parent 2bb45e6 commit b5522d2

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

backend/src/project/project.service.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import {
77
ForbiddenException,
88
} from '@nestjs/common';
99
import { InjectRepository } from '@nestjs/typeorm';
10-
import { Between, In, Not, Repository } from 'typeorm';
10+
import { Between, In, IsNull, Not, Repository } from 'typeorm';
1111
import { Project } from './project.model';
1212
import { ProjectPackages } from './project-packages.model';
1313
import {
@@ -637,6 +637,7 @@ export class ProjectService {
637637
const whereCondition = {
638638
isPublic: true,
639639
isDeleted: false,
640+
photoUrl: Not(IsNull()),
640641
};
641642

642643
if (input.strategy === 'latest') {

0 commit comments

Comments
 (0)