Third attempt at fixing #484. Part two