Updated from commit 986c2248e29c264857385eaecc2577909284b0d0.