Revert "Merge pull request #25589 from nullaus/bug1077595"

This reverts commit e9ac899aff346b2cef9be154290978fc18d1bc8f, reversing
changes made to 155f44a3063fdb7599208de9749ad487b870dd06.