Solution to #835