fixing syntax error in the off canvas reservation widget departure time
authorAnthony Talarico <talarico@gaslightmedia.com>
Tue, 14 Aug 2018 17:08:19 +0000 (13:08 -0400)
committerAnthony Talarico <talarico@gaslightmedia.com>
Tue, 14 Aug 2018 17:08:19 +0000 (13:08 -0400)
js/app.js
js/custom/pageSetup.js
style.css

index db64f14..d7ecbef 100644 (file)
--- a/js/app.js
+++ b/js/app.js
@@ -131,7 +131,8 @@ $(document).ready(function () {
         let formattedDate = `${year}-${month}-${day}`;
         _.val(formattedDate);
         let arrivalDate = new Date($("#arriveOff").val());
-        if( !isNaN( getNights(departDate,arrivalDate) ) && !getNights(departDate,arrivalDate) < 0){
+        
+        if( !isNaN( getNights(departDate,arrivalDate) ) && !getNights(departDate,arrivalDate) < 1){
             $("#nightsOff").val( getNights(departDate,arrivalDate) ) 
             stay = `stay_nights=${getNights(departDate,arrivalDate)}&`;
         }else {
index 695a86c..995005b 100644 (file)
@@ -122,7 +122,8 @@ $(document).ready(function () {
         let formattedDate = `${year}-${month}-${day}`;
         _.val(formattedDate);
         let arrivalDate = new Date($("#arriveOff").val());
-        if( !isNaN( getNights(departDate,arrivalDate) ) && !getNights(departDate,arrivalDate) < 0){
+        
+        if( !isNaN( getNights(departDate,arrivalDate) ) && !getNights(departDate,arrivalDate) < 1){
             $("#nightsOff").val( getNights(departDate,arrivalDate) ) 
             stay = `stay_nights=${getNights(departDate,arrivalDate)}&`;
         }else {
index 679e899..f346625 100644 (file)
--- a/style.css
+++ b/style.css
@@ -3,5 +3,5 @@ Theme Name: Staffords
 Author: Gaslight Media
 Author URI: http://www.gaslightmedia.com
 Description: A theme for Staffords
-Version: 1.0.49
+Version: 1.0.50
 */