Skip to content

Commit

Permalink
Update/remove Electrum servers and update some currency data (#588)
Browse files Browse the repository at this point in the history
- Remove a dead LTC Electrum server. jl777/coins@96bc16a
- Remove BCBC currency. Its Electrum servers are down. jl777/coins@ecc60d9
- Update QTUM Electrum servers. jl777/coins@acf8201
- Update BCH Electrum servers. jl777/coins@12726b0

`txversion:4`:
- jl777/coins@7ce1948
- jl777/coins@84e79d1
- jl777/coins@6e70bcd
  • Loading branch information
sindresorhus committed Jan 6, 2019
1 parent c206b7a commit ca25377
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 32 deletions.
41 changes: 14 additions & 27 deletions app/marketmaker/supported-currencies.js
Original file line number Diff line number Diff line change
Expand Up @@ -94,25 +94,6 @@ const supportedCurrencies = [
etomic: '0xFf3519eeeEA3e76F1F699CCcE5E23ee0bdDa41aC',
rpcport: 80,
},
{
coin: 'BCBC',
name: 'Bitcoin@CBC',
rpcport: 8340,
pubtype: 0,
p2shtype: 5,
wiftype: 128,
txfee: 10000,
electrumServers: [
{
host: 'bsmn0.cleanblockchain.io',
port: 50001,
},
{
host: 'bsmn1.cleanblockchain.org',
port: 50001,
},
],
},
{
coin: 'BCH',
rpcport: 33333,
Expand All @@ -130,9 +111,13 @@ const supportedCurrencies = [
port: 50001,
},
{
host: 'wallet.satoshiscoffeehouse.com',
host: 'electrum.imaginary.cash',
port: 50001,
},
{
host: 'abc1.hsmiths.com',
port: 60001,
},
],
},
{
Expand Down Expand Up @@ -445,6 +430,7 @@ const supportedCurrencies = [
name: 'CoinCollect',
asset: 'CCL',
rpcport: 20849,
txversion: 4,
electrumServers: [
{
host: 'electrum1.cipig.net',
Expand Down Expand Up @@ -1257,8 +1243,8 @@ const supportedCurrencies = [
port: 50001,
},
{
host: 'electrum-ltc.ddns.net',
port: 50001,
host: 'ltc01.knas.systems',
port: 50003,
},
{
host: 'electrum-ltc.wilv.in',
Expand Down Expand Up @@ -1707,19 +1693,19 @@ const supportedCurrencies = [
txfee: 400000,
electrumServers: [
{
host: 's1.qtum.info',
host: 's4.qtum.info',
port: 50001,
},
{
host: 's2.qtum.info',
host: 's5.qtum.info',
port: 50001,
},
{
host: 's3.qtum.info',
host: 's7.qtum.info',
port: 50001,
},
{
host: 's4.qtum.info',
host: 's8.qtum.info',
port: 50001,
},
],
Expand Down Expand Up @@ -2066,6 +2052,7 @@ const supportedCurrencies = [
name: 'VerusCoin',
asset: 'VRSC',
rpcport: 27486,
txversion: 4,
electrumServers: [
{
host: 'el0.vrsc.0x03.services',
Expand Down Expand Up @@ -2254,7 +2241,7 @@ const supportedCurrencies = [
pubtype: 184,
p2shtype: 189,
wiftype: 128,
txversion: 3,
txversion: 4,
txfee: 10000,
electrumServers: [
{
Expand Down
13 changes: 9 additions & 4 deletions app/portfolio-util.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,12 @@ class IncorrectPasswordError extends Error {
}
}

// Currencies that are removed from the app and should be removed from the user's portfolio
const removedCurrencies = [
'DNR',
'BCBC',
];

const createPortfolio = async ({name, seedPhrase, password}) => {
const id = generateId(name);
const filePath = idToFilePath(id);
Expand Down Expand Up @@ -83,10 +89,9 @@ const migrateEnabledCurrencies = async id => {
});
};

// TODO: Remove this sometime far in the future when everyone has migrated
const removeDnrCurrency = async id => {
const removeCurrenciesMigration = async id => {
await modifyPortfolio(id, portfolio => {
portfolio.currencies = portfolio.currencies.filter(currency => currency !== 'DNR');
portfolio.currencies = portfolio.currencies.filter(currency => !removedCurrencies.includes(currency));
});
};

Expand All @@ -112,7 +117,7 @@ const getPortfolios = async () => {
// TODO: Remove this sometime far in the future when everyone has migrated
await migrateEnabledCurrencies(portfolio.id);

await removeDnrCurrency(portfolio.id);
await removeCurrenciesMigration(portfolio.id);

return portfolio;
}));
Expand Down
1 change: 0 additions & 1 deletion app/renderer/block-explorer.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ const explorers = new Map(Object.entries({
AXE: 'http://207.246.65.114:3001/tx/{txid}',
AXO: 'https://axo.kmdexplorer.io/tx/{txid}',
BAY: 'https://chainz.cryptoid.info/bay/tx.dws?{txid}',
BCBC: 'http://be.cleanblockchain.org/tx/{txid}',
BCH: 'https://blockchair.com/bitcoin-cash/transaction/{txid}',
BCO: 'https://explorer.bridgecoin.org/tx/{txid}',
BDL: 'https://explorer.bitdeal.co.in/tx/{txid}',
Expand Down

0 comments on commit ca25377

Please sign in to comment.