title: TypeError: Cannot read property 'checked' of undefined
body: <p>I get this error in the console when I put in the time for the Monday From and Monday To inputs in the code below I have a switch that I want to copy the times I put in for Monday From/To for the rest of the week. Why am I geting this error and what do I do to fix it.</p>
  <p>Here is the code for the toggle switch button</p>
  <pre><code> &lt;b-form-checkbox switch v-model=&quot;providerScheduleDays.isCopytoMF&quot; 
    @change=&quot;toggleCopyMF($event.target.checked)&quot;&gt; Copy times to Mon-Fri&lt;/b-form-checkbox&gt;
  </code></pre>
  <p>Inputs for Monday to/from and Tuesday to/from</p>
  <pre><code>                            &lt;b-col lg=&quot;6&quot;&gt;
                                      &lt;!-- &lt;strong&gt;Monday&lt;/strong&gt; --&gt;
                                 &lt;common-forminputs-btextinputwithvalidation                                          
                                 :rules=&quot;`compare_to_end_time:${providerScheduleDays.mondayCloseHour}`&quot;
                                          label=&quot;Monday From&quot;
                                          requiredDisplayName=&quot;From&quot;
                                          v-model=&quot;providerScheduleDays.mondayOpenHour&quot;
                                          id=&quot;providerMondayOpen&quot;
                                          name=&quot;providerMondayOpen&quot;
                                          labelClass=&quot;w-50 pl-2&quot;
                                          inputClass=&quot;mb-2&quot;
                                          type=&quot;time&quot;/&gt;
                                        &lt;/b-col&gt; 
                                   
                                    &lt;b-col lg=&quot;6&quot;&gt;
                                     &lt;common-forminputs-btextinputwithvalidation                                            
                               :rules=&quot;`compare_to_start_time:${providerScheduleDays.mondayOpenHour}`&quot;
                                          label=&quot;Monday To&quot;
                                          requiredDisplayName=&quot;To&quot;
                                          v-model=&quot;providerScheduleDays.mondayCloseHour&quot;
                                          id=&quot;providerMondayClose&quot;
                                          name=&quot;providerMondayClose&quot;
                                          labelClass=&quot;w-50 pl-2&quot;
                                          inputClass=&quot;mb-2&quot;
                                          type=&quot;time&quot;/&gt;
                                    &lt;/b-col&gt;
                                  &lt;/b-row&gt;  
                                
                                  &lt;b-row class=&quot;pb-0&quot;&gt;
                                    &lt;b-col lg=&quot;6&quot;&gt;
                                      &lt;!-- &lt;strong&gt;Tuesday&lt;/strong&gt; --&gt;
                                      &lt;common-forminputs-btextinputwithvalidation                                          
                               :rules=&quot;`compare_to_end_time:${providerScheduleDays.tuesdayCloseHour}`&quot;
                                        label=&quot;Tuesday From&quot;
                                        requiredDisplayName=&quot;From&quot;
                                        v-model=&quot;providerScheduleDays.tuesdayOpenHour&quot;
                                        id=&quot;providerTuesdayOpen&quot;
                                        name=&quot;providerTuesdayOpen&quot;
                                        labelClass=&quot;w-50 pl-2&quot;
                                        inputClass=&quot;mb-2&quot;
                                        type=&quot;time&quot;                                                                                    
                                        @keyup=&quot;copyValuesMF($event.target.value)&quot;
                                      /&gt;
                                    &lt;/b-col&gt;
                                    
                                    &lt;b-col lg=&quot;6&quot;&gt;
                                      &lt;!-- &lt;strong&gt;Tuesday&lt;/strong&gt; --&gt;
                                      &lt;common-forminputs-btextinputwithvalidation                                          
                             :rules=&quot;`compare_to_start_time:${providerScheduleDays.tuesdayOpenHour}`&quot;
                                        label=&quot;Tuesday To&quot;
                                        requiredDisplayName=&quot;To&quot;
                                        v-model=&quot;providerScheduleDays.tuesdayCloseHour&quot;
                                        id=&quot;providerTuesdayClose&quot;
                                        name=&quot;providerTuesdayClose&quot;
                                        labelClass=&quot;w-50 pl-2&quot;
                                        inputClass=&quot;mb-2&quot;
                                        type=&quot;time&quot;                                                                                    
                                        @keyup=&quot;copyValuesMF($event.target.value)&quot;
                                      /&gt;
                                    &lt;/b-col&gt;
  </code></pre>
  <p>Function in typescript file</p>
  <pre><code>copyDate = false;
  toggleCopyMF(isActive: boolean) {this.copyDate = isActive 
  if(this.copyDate) {this.copyValuesMF(this.providerScheduleDays.mondayOpenHour); 
    this.copyValuesMF(this.providerScheduleDays.mondayCloseHour);
   } 
  }   
  copyValuesMF(value: string | undefined) {if(this.copyDate) {this.providerScheduleDays.tuesdayOpenHour 
   = value;
  this.providerScheduleDays.tuesdayCloseHour = value }     
  }
  </code></pre>