Revert the changes from PR 5152

The changes in 5152 appear to have introduced a
 performance problem on stage, so we're going to
 revert them for now.
Merge pull request #5266 from edx/andya/remove-pr-5152

Revert the changes from PR 5152