Updated the patch for #2175891 from Josh.