Skip to content

Commit

Permalink
Update carousel.js
Browse files Browse the repository at this point in the history
animateCarousel function: return if carousel is null
  • Loading branch information
bwbohl committed Dec 6, 2022
1 parent 54ff026 commit 7c89d97
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions js/carousel.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ let intervals = [];
*/
function animateCarousel(carousel, milliseconds) {
"use strict";
if (carousel === null) return;
const slides = carousel.getElementsByClassName("carousel-locator");
const id = carousel.id;
var slideIndex = 0;
Expand Down

0 comments on commit 7c89d97

Please sign in to comment.