Changed condition on size check for number->bits.