This repository has been archived by the owner on Sep 5, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Minor fixes on the internal links (#1323) * Tens of new ABI signatures (#1341) * Electron package renaming & Readme updates (#1339) * Renaming electron-prebuilt to electron * Updating Readme instructions * [npm] tighten versions in dependency-graph * Fix shell v ul ns (#1354) * fix vulns * readd syncminimongo to popupWindows * Removing duplicated instruction * Version bump (#1356)
- Loading branch information
1 parent
0df1f22
commit 7eb2d2f
Showing
19 changed files
with
359 additions
and
152 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
"use strict"; | ||
|
||
const _ = global._; | ||
const BaseProcessor = require('./base'); | ||
const db = require('../../db'); | ||
|
||
/** | ||
* Process method: eth_coinbase | ||
*/ | ||
module.exports = class extends BaseProcessor { | ||
/** | ||
* @override | ||
*/ | ||
sanitizeResponsePayload (conn, payload, isPartOfABatch) { | ||
this._log.trace('Sanitize account eth_coinbase', payload.result); | ||
|
||
// if not an admin connection then do a check | ||
if (!this._isAdminConnection(conn)) { | ||
let tab = db.getCollection('tabs').findOne({ webviewId: conn.id }); | ||
|
||
if(_.get(tab, 'permissions.accounts')) { | ||
payload.result = _.contains(tab.permissions.accounts, payload.result) ? payload.result : null; | ||
} else { | ||
payload.result = null; | ||
} | ||
} | ||
|
||
return super.sanitizeResponsePayload(conn, payload, isPartOfABatch); | ||
} | ||
} | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.