title: Diff is not a function in Moment.js
body: <p>I am selecting a date in the Air Datepicker and trying to compare today's date to the selected date to determine the difference in days. So, for example, if today is 12/11/2016 and I select 12/20/2016, I want to get the difference, which is 9. </p>
  
  <p>I keep running into the following error: "end.diff is not a function".</p>
  
  <p>I've stripped the following code down to the essentials:</p>
  
  <p><strong>HTML</strong></p>
  
  <pre><code>&lt;form&gt;
      &lt;input id="datereq" name="datereq" type="text" class="dateReq" value="" /&gt;
  &lt;/form&gt;
  &lt;div id="selected"&gt;&lt;/div&gt;
  </code></pre>
  
  <p><strong>JQUERY</strong></p>
  
  <pre><code> var date = new Date(),
       disabledDays = [0, 6];
  
   $('.dateReq').datepicker({
       dateFormat: 'mm/dd/yyyy',
       minDate: new Date(),
       language: 'en',
       autoClose: true,
       onRenderCell: function(date, cellType) {
           if (cellType == 'day') {
               var day = date.getDay(),
                   isDisabled = disabledDays.indexOf(day) != -1;
               return {
                   disabled: isDisabled
               };
           }
       },
  
       // Display Appropriate Order Type Options
       onSelect: function onSelect(fd, date) {
           var now = moment(new Date()).format('MM/DD/YYYY'),
               end = fd,
               days = end.diff(now, 'days');
           $('#selected').html('now:' + now + 'end:' + end + 'diff:' + days);
           //console.log('end:' + end);
           //console.log('diff:' + days);
       }
   });
  </code></pre>
  
  <p><strong>Fiddle</strong></p>
  
  <p><a href="https://jsfiddle.net/qn530dpq/" rel="noreferrer">https://jsfiddle.net/qn530dpq/</a></p>