fix for issue 496