$amount = (int) $amount; as well.