[AVLE] Editing account's profile using Keychain

in avle •  3 years ago 

I have implemented editing account's profile using keychain.

I thought there is no function to update profile in steem keychain. But it was my misunderstanding.

I can use the requestBroadcast function to update profile like this for Flutter.

 final operations = dartJs.JsObject.jsify([
        [
          'account_update2',
          {
            'account': username,
            'json_metadata': '',
            'posting_json_metadata': jsonEncode(profileMeta)
          },
        ]
      ]);

      await steemKeychain.requestBroadcast(
        username: username,
        operations: operations,
        keyType: 'Posting',
        callback: dartJs.allowInterop(
          (response) {
            print('requestBroadcast. updateProfile: ${response['message']}');
            print(
                'requestBroadcast update profile  response success: ${response['success']}');
            if (response['success']) {
              // handleKeychainResult(response);
            } else {
              printError('failed to update profile. ${response['message']}');
            }
          },
        ),
      );

Edit Account's Profile

To edit the profile, click the gear button in the profile screen.
image.png

Update Profile

Here I changed the display name to "etain12"

image.png

After clicking the update button, then keychain appears like above.

This operation seems not applied directly when I check in steemit.com.

But when visiting steemworld.org, I can see the account_update2 operation right there!

image.png

Based on my development experience, it takes some time to be updated. Let's see what will happen after some time.

Authors get paid when people like you upvote their post.
If you enjoyed what you read here, create your account today and start earning FREE BLURT!
Sort Order:  

Congratulations, your post has been curated by @dsc-r2cornell. You can use the tag #R2cornell. Also, find us on Discord

Manually curated by Blessed-girl

logo3 Discord.png

Felicitaciones, su publicación ha sido votada por @ dsc-r2cornell. Puedes usar el tag #R2cornell. También, nos puedes encontrar en Discord

  ·  3 years ago  ·  

I so pleased to your creativity.
You are doing well.