Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feature: type/store.js leveldb integration #107

Open
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

victorwu
Copy link
Contributor

#Summary

This feature integrates leveldb database storage functions into types/store. This would enable further account and identity storage, allowing users to have better profile management when accessing various fabric applications. Functions in fabric-browser-extension have also been migrated to use types/store in @fabric/core.

  • updated level to latest version, including updating code syntax
  • added leveldb functions
    • createDB, initDB, clearDatabase,
  • added account functions
    • setSeedPhrase, insertAccount, insertIdentity, getAccountValid, retrievePrivateKey, getIdentityCount
  • added settings config functions
    • setDBIdentityCheckState, getGlobalChainState, getAccount, checkPassword, changePassword

@victorwu victorwu requested a review from martindale September 23, 2022 22:52
@victorwu victorwu marked this pull request as ready for review September 23, 2022 22:52
@martindale martindale requested a review from manojdv October 3, 2022 18:52
Copy link
Member

@martindale martindale left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some of the methods added to Store can be migrated to Identity, Environment, or other — will work with @victorwu to get everything in appropriate places

@@ -102,7 +102,7 @@
"javascript-state-machine": "3.1.0",
"jayson": "4.0.0",
"json-pointer": "0.6.2",
"level": "7.0.1",
"level": "^8.0.0",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove the caret to pin to this version (prevents dependency changes unless explicitly desired)


/**
* Insert identity into store of specified account index.
* @param {IIdentity} identity array of identities generated from account.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants