OSDN Git Service

add the init value for account alias.
authorZhiting Lin <zlin035@uottawa.ca>
Wed, 14 Nov 2018 11:12:12 +0000 (19:12 +0800)
committerZhiting Lin <zlin035@uottawa.ca>
Wed, 14 Nov 2018 11:12:12 +0000 (19:12 +0800)
src/features/accounts/components/AccountUpdate.jsx

index 0d89399..72c3b48 100644 (file)
@@ -75,10 +75,9 @@ const mapStateToProps = (state, ownProps) => ({
 const initialValues = (state, ownProps) => {
   const item = state.account.items[ownProps.params.id]
   if (item) {
-    const tags = Object.keys(item.tags || {}).length === 0 ? '{\n\t\n}' : JSON.stringify(item.tags || {}, null, 1)
     return {
       initialValues: {
-        tags: tags
+        alias: item.alias
       }
     }
   }