From 3e42929f9024acb0e3557c48b3ed5ad6ffcc0072 Mon Sep 17 00:00:00 2001
From: Mike Mellor <mike.mellor@f-grp.com>
Date: Fri, 13 Nov 2015 15:13:30 +0000
Subject: [PATCH] check for 0 division, stops parallax failing if only the
 single horizontal slide and multiple vertical

---
 js/reveal.js | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/js/reveal.js b/js/reveal.js
index d2b29705..266df2c8 100644
--- a/js/reveal.js
+++ b/js/reveal.js
@@ -2798,7 +2798,7 @@
 				horizontalOffsetMultiplier = config.parallaxBackgroundHorizontal;
 			}
 			else {
-				horizontalOffsetMultiplier = ( backgroundWidth - slideWidth ) / ( horizontalSlideCount-1 );
+				horizontalOffsetMultiplier = ( horizontalSlideCount-1  > 0) ? ( backgroundWidth - slideWidth ) / ( horizontalSlideCount-1 ) : 0;
 			}
 
 			horizontalOffset = horizontalOffsetMultiplier * indexh * -1;
-- 
GitLab