Updated from commit 8c01557fe1afc2287225efb5717cca3df3e8f26a.