summaryrefslogtreecommitdiff
path: root/packages/backend/src/misc/is-not-null.ts
blob: d89a1957be2c313c1013a54b14da3a640256b5d8 (plain)
1
2
3
4
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;
}