Skip to content

Commit

Permalink
Feature: collectibles api key (#603)
Browse files Browse the repository at this point in the history
* add opensea key from env

* bump gaba

* change const name
  • Loading branch information
estebanmino authored Apr 11, 2019
1 parent 9e8ef94 commit 164f0fe
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 37 deletions.
3 changes: 3 additions & 0 deletions app/core/Engine.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ import { store } from '../store';
import { renderFromTokenMinimalUnit, balanceToFiatNumber, weiToFiatNumber } from '../util/number';
import TransactionsNotificationManager from './TransactionsNotificationManager';

const OPENSEA_API_KEY = process.env['MM_OPENSEA_KEY']; // eslint-disable-line dot-notation
const encryptor = new Encryptor();
let refreshing = false;
/**
Expand Down Expand Up @@ -158,11 +159,13 @@ class Engine {
);

const {
AssetsController: assets,
KeyringController: keyring,
NetworkController: network,
TransactionController: transaction
} = this.datamodel.context;

assets.setApiKey(OPENSEA_API_KEY);
network.refreshNetwork();
transaction.configure({ sign: keyring.signTransaction.bind(keyring) });
network.subscribe(this.refreshNetwork);
Expand Down
53 changes: 17 additions & 36 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@
"ethjs-unit": "0.1.6",
"events": "3.0.0",
"fuse.js": "3.4.4",
"gaba": "1.0.0-beta.72",
"gaba": "1.0.0-beta.73",
"https-browserify": "0.0.1",
"jsc-android": "236355.1.1",
"multihashes": "0.4.14",
Expand Down

0 comments on commit 164f0fe

Please sign in to comment.