issue 1676 fix bug