 
 formatCardNumber = (maxLength) -> (e) ->
   # Only format if input is a number
-  digit = String.fromCharCode(e.which)
-  return unless /^\d+$/.test(digit)
-
-  target = e.target
-  value   = QJ.val(target)
-  card    = cardFromNumber(value + digit)
-  length  = (value.replace(/\D/g, '') + digit).length
+  if e.which > 0 
+    digit = String.fromCharCode(e.which);
+    value = QJ.val(e.target) + digit
+  else # android keycode not provided workaround
+    digit = e.data;
+    value = QJ.val(e.target)
+  
+  return unless /^\d+$/.test(digit)
+
+  target = e.target
+  card    = cardFromNumber(value)
+  length  = (value.replace(/\D/g, '')).length
 
   upperLengths = [16]
   upperLengths = card.length if card

# Format Expiry

formatExpiry = (e) ->
  # Only format if input is a number
  digit = String.fromCharCode(e.which)
  return unless /^\d+$/.test(digit)

  target = e.target
  val     = QJ.val(target) + digit

  if /^\d$/.test(val) and val not in ['0', '1']
    e.preventDefault()
    QJ.val(target, "0#{val} / ")
    QJ.trigger(target, 'change')

    QJ.on el, 'keydown', formatBackCardNumber
    QJ.on el, 'keyup blur', setCardType
    QJ.on el, 'paste', reFormatCardNumber
    QJ.on el, 'input', formatCardNumber(maxLength)
    el
  @getCardArray: -> return cards
  @setCardArray: (cardArray) ->
