strictNullChecks (#4666)

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* wip
This commit is contained in:
syuilo 2019-04-13 01:43:22 +09:00 committed by GitHub
parent 4ee40c3345
commit 987168b863
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
214 changed files with 939 additions and 785 deletions

View file

@ -17,10 +17,10 @@ export default class extends Channel {
@autobind
private async onNote(note: any) {
// その投稿のユーザーをフォローしていなかったら弾く
if (this.user.id !== note.userId && !this.following.includes(note.userId)) return;
if (this.user!.id !== note.userId && !this.following.includes(note.userId)) return;
if (['followers', 'specified'].includes(note.visibility)) {
note = await Notes.pack(note.id, this.user, {
note = await Notes.pack(note.id, this.user!, {
detail: true
});
@ -30,13 +30,13 @@ export default class extends Channel {
} else {
// リプライなら再pack
if (note.replyId != null) {
note.reply = await Notes.pack(note.replyId, this.user, {
note.reply = await Notes.pack(note.replyId, this.user!, {
detail: true
});
}
// Renoteなら再pack
if (note.renoteId != null) {
note.renote = await Notes.pack(note.renoteId, this.user, {
note.renote = await Notes.pack(note.renoteId, this.user!, {
detail: true
});
}