issue-174: restored from master