Skip to content

Commit

Permalink
Merge pull request #2632 from SelfKeyFoundation/release
Browse files Browse the repository at this point in the history
Release 1.9.12
  • Loading branch information
andregoncalves authored Sep 13, 2021
2 parents 85af64f + 2f5113a commit 1f0f602
Show file tree
Hide file tree
Showing 8 changed files with 29 additions and 8 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "selfkey-identity-wallet",
"productName": "SelfKey Identity Wallet",
"version": "1.9.11",
"version": "1.9.12",
"description": "The Official SelfKey Identity Wallet for Desktop",
"browser": [
"chrome"
Expand Down
5 changes: 4 additions & 1 deletion src/main/marketplace/inventory/inventory-service.js
Original file line number Diff line number Diff line change
Expand Up @@ -127,8 +127,11 @@ export class SelfkeyInventoryFetcher extends InventoryFetcher {
}
}
async fetchData(category) {
if (category === 'other' || !category) {
return;
}
if (!dataEndpoints[category]) {
throw new Error('unknown_data_category');
throw new Error(`unknown_data_category ${category}`);
}
try {
let fetched = await request.get({ url: dataEndpoints[category], json: true });
Expand Down
5 changes: 4 additions & 1 deletion src/renderer/did/create-did-popup-container.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,10 @@ class CreateDIDPopupContainerComponent extends PureComponent {

getPaymentParameters = _ => {
const { ethRate, ethGasStationInfo, cryptoCurrency, gasLimit } = this.props;
const gasPrice = ethGasStationInfo.medium.suggestedMaxFeePerGas;
const gasPrice =
ethGasStationInfo && ethGasStationInfo.medium
? ethGasStationInfo.medium.suggestedMaxFeePerGas
: 0;
const ethFee = EthUnits.toEther(gasPrice * gasLimit, 'gwei');
const usdFee = ethFee * ethRate;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,10 @@ class BankAccountsCheckoutContainer extends MarketplaceBankAccountsComponent {

getPaymentParameters() {
const { keyRate, ethRate, ethGasStationInfo, cryptoCurrency, jurisdiction } = this.props;
const gasPrice = ethGasStationInfo.medium.suggestedMaxFeePerGas;
const gasPrice =
ethGasStationInfo && ethGasStationInfo.medium
? ethGasStationInfo.medium.suggestedMaxFeePerGas
: 0;
const price = jurisdiction.price;
const keyAmount = price / keyRate;
const gasLimit = FIXED_GAS_LIMIT_PRICE;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,10 @@ class IncorporationsCheckoutContainer extends MarketplaceIncorporationsComponent

getPaymentParameters() {
const { keyRate, ethRate, ethGasStationInfo, cryptoCurrency, program } = this.props;
const gasPrice = ethGasStationInfo.medium.suggestedMaxFeePerGas;
const gasPrice =
ethGasStationInfo && ethGasStationInfo.medium
? ethGasStationInfo.medium.suggestedMaxFeePerGas
: 0;
const price = program.price;
const keyAmount = price / keyRate;
const gasLimit = FIXED_GAS_LIMIT_PRICE;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,10 @@ class MarketplaceKeyFiCheckoutContainerComponent extends MarketplaceKeyFiCompone

getPaymentParameters() {
const { keyRate, ethRate, ethGasStationInfo, cryptoCurrency, product } = this.props;
const gasPrice = ethGasStationInfo.medium.suggestedMaxFeePerGas;
const gasPrice =
ethGasStationInfo && ethGasStationInfo.medium
? ethGasStationInfo.medium.suggestedMaxFeePerGas
: 0;
const price = product.price;
const ethPrice = price;
const keyPrice = price * 0.8;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,10 @@ class RequestNotarizationContainer extends MarketplaceNotariesComponent {

getPaymentParameters() {
const { ethRate, ethGasStationInfo } = this.props;
const gasPrice = ethGasStationInfo.medium.suggestedMaxFeePerGas;
const gasPrice =
ethGasStationInfo && ethGasStationInfo.medium
? ethGasStationInfo.medium.suggestedMaxFeePerGas
: 0;
const gasLimit = FIXED_GAS_LIMIT_PRICE;
const gasEthFee = EthUnits.toEther(gasPrice * gasLimit, 'gwei');
const gasUsdFee = gasEthFee * ethRate;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,10 @@ class PassportsCheckoutContainerComponent extends MarketplacePassportsComponent

getPaymentParameters() {
const { keyRate, ethRate, ethGasStationInfo, cryptoCurrency, program } = this.props;
const gasPrice = ethGasStationInfo.medium.suggestedMaxFeePerGas;
const gasPrice =
ethGasStationInfo && ethGasStationInfo.medium
? ethGasStationInfo.medium.suggestedMaxFeePerGas
: 0;
const price = program.price;
const keyAmount = price / keyRate;
const gasLimit = FIXED_GAS_LIMIT_PRICE;
Expand Down

0 comments on commit 1f0f602

Please sign in to comment.