function UDecimalPad(num, precision) {
    var value = UDecimalString(num);
    assert.equal("number", typeof precision === 'undefined' ? 'undefined' : (0, _typeof3.default)(precision), "precision");

    var part = value.split(".");

    if (precision === 0 && part.length === 1) {
        return part[0];
    }

    if (part.length === 1) {
        return part[0] + '.' + "0".repeat(precision);
    } else {
        var pad = precision - part[1].length;
        assert(pad >= 0, 'decimal \'' + value + '\' exceeds precision ' + precision);
        return part[0] + '.' + part[1] + "0".repeat(pad);
    }
}