solved #72, #79, and #89