Revert "Fixes bug described in #3581"

This reverts commit 6c75e3697d5b0d70ed0cc73403b16d2812bd02ad.