Use null assertions instead of casting.

This commit is contained in:
Paul
2021-06-21 09:02:38 +01:00
parent d1bff98635
commit 3555e9a7bf
4 changed files with 5 additions and 5 deletions

View File

@@ -18,7 +18,7 @@ export default function TextFile({ attachment }: Props) {
const status = useContext(StatusContext);
const client = useContext(AppContext);
const url = client.generateFileURL(attachment);
const url = client.generateFileURL(attachment)!;
useEffect(() => {
if (typeof content !== 'undefined') return;