fix for #771

issue #771