fix #81, #100
fix #101