Fix bug in `toDpi()`