Refactor #3985: Correction of bug