fixes #406
fixes #407
fix #405