Decimal values can not be specified for the integer! Check 2.($count) parameter!'); } } /** * Up * * @param float $number * @param int $count = 0 * * @return float */ public static function up(Float $number, int $count = 0) : Float { if( $count === 0 ) { return ceil($number); } $numbers = explode(".", $number); $edit = 0; if( ! empty($numbers[1]) ) { $edit = substr($numbers[1], 0, $count); return (float) $numbers[0].".".($edit + 1); } else { throw new LogicException('[Rounder::up()] -> Decimal values can not be specified for the integer! Check 2.($count) parameter!'); } } }