am 8ebb189f: am 7f2927a0: am 4889048e: am c5517b3e: Protect against class cast exception DO NOT MERGE

* commit '8ebb189f2dbe40ec34eb9814936a1a9d8024ee7f':
  Protect against class cast exception DO NOT MERGE