通知部分は残す
Co-Authored-By: rinsuki <428rinsuki+contact.github@gmail.com>
This commit is contained in:
parent
a7c82eeabc
commit
ad7ecbaf37
2 changed files with 35 additions and 54 deletions
5
packages/backend/src/misc/is-not-null.ts
Normal file
5
packages/backend/src/misc/is-not-null.ts
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
// we are using {} as "any non-nullish value" as expected
|
||||
// eslint-disable-next-line @typescript-eslint/ban-types
|
||||
export function isNotNull<T extends {}>(input: T | undefined | null): input is T {
|
||||
return input != null;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue