fix for #939