Updated from commit ebbec9bfb7b422b58353b872c36d12af2f931a88.