fixed #1, fixed #9