Un-revert PR #530

This reverts commit 68c71ec48f16eac6f8aff2a66496afb148ec95c6.