Fix for #1213