Fixed bug described in #194