synchronization with auth branch
Merge branch 'master' into beta
fixed possible NPE
Merge branch 'master' into beta