fixes #1979
fixes #1978

Related to #1316