fixing a bug related to the issue #119