Additional fixes for #2728