From 3b3ffb468f4b01f1255e85512edbde2c266e297b Mon Sep 17 00:00:00 2001 From: Kaveet Laxmidas Date: Tue, 13 Aug 2019 14:49:04 -0500 Subject: [PATCH] Fix reference to undefined variable Replace an undefined variable with a jQuery-wrapped `this`. The original code appears to have a typo. --- src/js/page.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/js/page.js b/src/js/page.js index fc132af..14b0abc 100644 --- a/src/js/page.js +++ b/src/js/page.js @@ -26,7 +26,7 @@ $(document).ready(() => { if ($figcaption) { $(this).attr('alt', $figcaption.text()) } else { - $this.attr('alt', '') + $(this).attr('alt', '') } })