mirror of
https://iceshrimp.dev/limepotato/jormungandr-bite.git
synced 2024-11-13 13:37:31 -07:00
Fix type
This commit is contained in:
parent
0a250d0327
commit
31e6d071fa
2 changed files with 2 additions and 2 deletions
|
@ -1,7 +1,7 @@
|
|||
import { User } from '../../../models/entities/user';
|
||||
import { Brackets, SelectQueryBuilder } from 'typeorm';
|
||||
|
||||
export function generateRepliesQuery(q: SelectQueryBuilder<any>, me?: User) {
|
||||
export function generateRepliesQuery(q: SelectQueryBuilder<any>, me?: User | null) {
|
||||
if (me == null) {
|
||||
q.andWhere(new Brackets(qb => { qb
|
||||
.where(`note.replyId IS NULL`) // 返信ではない
|
||||
|
|
|
@ -2,7 +2,7 @@ import { User } from '../../../models/entities/user';
|
|||
import { Followings } from '../../../models';
|
||||
import { Brackets, SelectQueryBuilder } from 'typeorm';
|
||||
|
||||
export function generateVisibilityQuery(q: SelectQueryBuilder<any>, me?: User) {
|
||||
export function generateVisibilityQuery(q: SelectQueryBuilder<any>, me?: User | null) {
|
||||
if (me == null) {
|
||||
q.andWhere(new Brackets(qb => { qb
|
||||
.where(`note.visibility = 'public'`)
|
||||
|
|
Loading…
Reference in a new issue