Skip to content
This repository has been archived by the owner on Nov 6, 2020. It is now read-only.

Commit

Permalink
Backporting to beta (#4840)
Browse files Browse the repository at this point in the history
* Fixes to the Registry dapp (#4838)

* Fix wrong ABI methods

* Fix

* v1.6.1
  • Loading branch information
arkpar authored and gavofyork committed Mar 10, 2017
1 parent 70d17ce commit d25a20b
Show file tree
Hide file tree
Showing 8 changed files with 45 additions and 37 deletions.
50 changes: 25 additions & 25 deletions Cargo.lock

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

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[package]
description = "Parity Ethereum client"
name = "parity"
version = "1.6.0"
version = "1.6.1"
license = "GPL-3.0"
authors = ["Parity Technologies <admin@parity.io>"]

Expand Down
17 changes: 12 additions & 5 deletions js/src/dapps/registry/Lookup/actions.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
// You should have received a copy of the GNU General Public License
// along with Parity. If not, see <http://www.gnu.org/licenses/>.

import { sha3 } from '../parity.js';
import { api, sha3 } from '../parity.js';
import { getOwner } from '../util/registry';

export const clear = () => ({ type: 'lookup clear' });
Expand All @@ -34,14 +34,21 @@ export const lookup = (name, key) => (dispatch, getState) => {
return;
}

const getAddress = contract.functions
.find((f) => f.name === 'getAddress');
const method = key === 'A'
? contract.instance.getAddress
: contract.instance.getData;

name = name.toLowerCase();
dispatch(lookupStart(name, key));

getAddress.call({}, [ sha3.text(name), key ])
.then((address) => dispatch(success('lookup', address)))
method.call({}, [ sha3.text(name), key ])
.then((result) => {
if (key !== 'A') {
result = api.util.bytesToHex(result);
}

dispatch(success('lookup', result));
})
.catch((err) => {
console.error(`could not lookup ${key} for ${name}`);
if (err) {
Expand Down
5 changes: 3 additions & 2 deletions js/src/dapps/registry/Records/actions.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,9 @@ export const update = (name, key, value) => (dispatch, getState) => {
throw new Error(`you are not the owner of "${name}"`);
}

const fnName = key === 'A' ? 'setAddress' : 'set';
const method = contract.instance[fnName];
const method = key === 'A'
? contract.instance.setAddress
: contract.instance.setData || contract.instance.set;

const options = {
from: account.address
Expand Down
2 changes: 1 addition & 1 deletion js/src/dapps/registry/ui/image.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ export default (address) => {

return (
<img
src={ `${parityNode}/${address}/` }
src={ `${parityNode}/api/content/${address.replace(/^0x/, '')}` }
alt={ address }
style={ styles }
/>
Expand Down
2 changes: 1 addition & 1 deletion mac/Parity.pkgproj
Original file line number Diff line number Diff line change
Expand Up @@ -462,7 +462,7 @@
<key>OVERWRITE_PERMISSIONS</key>
<false/>
<key>VERSION</key>
<string>1.6.0</string>
<string>1.6.1</string>
</dict>
<key>UUID</key>
<string>2DCD5B81-7BAF-4DA1-9251-6274B089FD36</string>
Expand Down
2 changes: 1 addition & 1 deletion nsis/installer.nsi
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
!define DESCRIPTION "Fast, light, robust Ethereum implementation"
!define VERSIONMAJOR 1
!define VERSIONMINOR 6
!define VERSIONBUILD 0
!define VERSIONBUILD 1
!define ARGS "--warp"
!define FIRST_START_ARGS "ui --warp --mode=passive"

Expand Down
2 changes: 1 addition & 1 deletion util/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ description = "Ethcore utility library"
homepage = "http://parity.io"
license = "GPL-3.0"
name = "ethcore-util"
version = "1.6.0"
version = "1.6.1"
authors = ["Parity Technologies <admin@parity.io>"]
build = "build.rs"

Expand Down

0 comments on commit d25a20b

Please sign in to comment.