From 6ade929dd8a110b1820f1bdf28e7b8f50e439dfb Mon Sep 17 00:00:00 2001 From: Nicholas March Date: Thu, 11 Jul 2024 12:00:48 -0700 Subject: [PATCH] reference username instead of name --- book-content/chapters/05-unions-literals-and-narrowing.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/book-content/chapters/05-unions-literals-and-narrowing.md b/book-content/chapters/05-unions-literals-and-narrowing.md index 506c7ee..55499e4 100644 --- a/book-content/chapters/05-unions-literals-and-narrowing.md +++ b/book-content/chapters/05-unions-literals-and-narrowing.md @@ -577,7 +577,7 @@ In this case, if `username` is not a string, we know it's `null` and could retur ```typescript function validateUsername(username: string | null | undefined): boolean { - if (typeof name !== "string") { + if (typeof username !== "string") { return false; }