Updated from commit 63b5f75a7f290af01979520f4ce440621b299fe5.