added NPE guard for mAdapter
Merge pull request #55 from mingfai/master

added NPE guard for mAdapter