Fixes issue #1940 (maintenance-3.x)

Fixes issue #1940 (maintenance-3.x)