title: java.lang.StringIndexOutOfBoundsException: length=1; index=1
body: <p>here is my code
  App is crashing when opening this activity
  Please help
  Below is the error
  This is not the full code</p>
  
  <pre><code>public void onBindViewHolder(final MyViewHolder holder, final int position) {
  
      final ModelTimeSlot  modelTimeSlot = arrayList.get(position);
      holder.checkBox.setText(modelTimeSlot.name);
      holder.checkBox.setChecked(modelTimeSlot.selected);
      holder.checkBox.setTag(new Integer(position));
      int hr = Integer.parseInt(currentHrs);
      int minutes = Integer.parseInt(currentMin);
      int h = Integer.parseInt(String.valueOf(modelTimeSlot.endTime.charAt(0))
              + String.valueOf(modelTimeSlot.endTime.charAt(1)));
  
      int m = Integer.parseInt(String.valueOf(modelTimeSlot.endTime.charAt(2))
              + String.valueOf(modelTimeSlot.endTime.charAt(3)));
  </code></pre>
  
  <p>And here is the error</p>
  
  <pre><code>at java.lang.String.indexAndLength(String.java:500)
  at java.lang.String.charAt(String.java:494)
  at mrhot.com.mrhot.Adapter.AdapterTimeSlot.onBindViewHolder(AdapterTimeSlot.java:91)
  at mrhot.com.mrhot.Adapter.AdapterTimeSlot.onBindViewHolder(AdapterTimeSlot.java:28)
  </code></pre>