worked on #9
finally fixed #9