Skip to content

Commit

Permalink
Merge pull request #123 from NazarUsov/testnet/issues
Browse files Browse the repository at this point in the history
Fix bigNumberParcer
  • Loading branch information
sowle authored Jul 26, 2024
2 parents 2fb143c + 5a73d39 commit 41a701f
Show file tree
Hide file tree
Showing 8 changed files with 147 additions and 151 deletions.
56 changes: 28 additions & 28 deletions html/main.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion html/main.js.map

Large diffs are not rendered by default.

198 changes: 91 additions & 107 deletions html/polyfills.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion html/polyfills.js.map

Large diffs are not rendered by default.

17 changes: 7 additions & 10 deletions html/vendor.js
Original file line number Diff line number Diff line change
Expand Up @@ -219830,9 +219830,8 @@ function __await(v) {
function __asyncGenerator(thisArg, _arguments, generator) {
if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined.");
var g = generator.apply(thisArg, _arguments || []), i, q = [];
return i = {}, verb("next"), verb("throw"), verb("return", awaitReturn), i[Symbol.asyncIterator] = function () { return this; }, i;
function awaitReturn(f) { return function (v) { return Promise.resolve(v).then(f, reject); }; }
function verb(n, f) { if (g[n]) { i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; if (f) i[n] = f(i[n]); } }
return i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i;
function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }
function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }
function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }
function fulfill(value) { resume("next", value); }
Expand Down Expand Up @@ -219898,18 +219897,16 @@ function __classPrivateFieldIn(state, receiver) {
function __addDisposableResource(env, value, async) {
if (value !== null && value !== void 0) {
if (typeof value !== "object" && typeof value !== "function") throw new TypeError("Object expected.");
var dispose, inner;
var dispose;
if (async) {
if (!Symbol.asyncDispose) throw new TypeError("Symbol.asyncDispose is not defined.");
dispose = value[Symbol.asyncDispose];
if (!Symbol.asyncDispose) throw new TypeError("Symbol.asyncDispose is not defined.");
dispose = value[Symbol.asyncDispose];
}
if (dispose === void 0) {
if (!Symbol.dispose) throw new TypeError("Symbol.dispose is not defined.");
dispose = value[Symbol.dispose];
if (async) inner = dispose;
if (!Symbol.dispose) throw new TypeError("Symbol.dispose is not defined.");
dispose = value[Symbol.dispose];
}
if (typeof dispose !== "function") throw new TypeError("Object not disposable.");
if (inner) dispose = function() { try { inner.call(this); } catch (e) { return Promise.reject(e); } };
env.stack.push({ value: value, dispose: dispose, async: async });
}
else if (async) {
Expand Down
2 changes: 1 addition & 1 deletion html/vendor.js.map

Large diffs are not rendered by default.

19 changes: 17 additions & 2 deletions html_source/src/app/api/services/backend.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,22 @@ export class BackendService {
static bigNumberParser(key, val): any {
if (
val.constructor.name === 'BigNumber' &&
['balance', 'unlocked_balance', 'amount', 'fee', 'b_fee', 'to_pay', 'a_pledge', 'b_pledge', 'coast', 'a'].indexOf(key) === -1
[
'balance',
'unlocked_balance',
'amount',
'fee',
'b_fee',
'to_pay',
'a_pledge',
'b_pledge',
'coast',
'a',
'total',
'unlocked',
'current_supply',
'total_max_supply',
].indexOf(key) === -1
) {
return val.toNumber();
}
Expand Down Expand Up @@ -706,7 +721,7 @@ export class BackendService {
response: JSON.parse(json_resp),
};
console.group(`----------- ${Commands.dispatch_async_call_result} -----------`);
console.log(asyncCommandResults);
console.log(asyncCommandResults);
console.groupEnd();
this.ngZone.run(() => setTimeout(() => this.dispatchAsyncCallResult$.next(asyncCommandResults), 250));
});
Expand Down
2 changes: 1 addition & 1 deletion html_source/src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { AppModule } from './app/app.module';
import { environment } from './environments/environment';
import 'lodash';

export const buildTime = '2024-07-10T12:56:54.196Z';
export const buildTime = '2024-07-22T08:42:28.610Z';

if (environment.production) {
enableProdMode();
Expand Down

0 comments on commit 41a701f

Please sign in to comment.