fix class cast exception
Merge branch '0.50' of git://github.com/qii/weiciyuan into 0.50