Adjust for new contract wrapper (WIP)

This commit is contained in:
2017-08-12 13:59:18 +02:00
parent b1db64a07d
commit 72cf4b495e
6 changed files with 12526 additions and 40 deletions
+3 -3
View File
@@ -13,7 +13,7 @@ export default Ember.Object.extend({
github_username: null,
github_uid: null,
wiki_username: null,
ipfsHash: null,
profileHash: null,
kredits: null,
isCore: false,
isCurrentUser: false,
@@ -32,7 +32,7 @@ export default Ember.Object.extend({
*/
loadProfile(ipfs) {
let promise = new Ember.RSVP.Promise((resolve, reject) => {
ipfs.getFile(this.get('ipfsHash')).then(content => {
ipfs.getFile(this.get('profileHash')).then(content => {
let profileJSON = JSON.parse(content);
let profile = Ember.Object.create(profileJSON);
@@ -60,7 +60,7 @@ export default Ember.Object.extend({
Ember.Logger.debug('[contributor] loaded contributor profile', profile);
resolve();
}).catch((err) => {
Ember.Logger.error('[contributor] error trying to load contributor profile', this.get('ipfsHash'), err);
Ember.Logger.error('[contributor] error trying to load contributor profile', this.get('profileHash'), err);
reject(err);
});
});