Skip to content

Commit

Permalink
Fix attribute functions
Browse files Browse the repository at this point in the history
  • Loading branch information
kamicut committed Sep 2, 2021
1 parent 3e8267e commit 8a43037
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions pages/team-edit-profile.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import Popup from 'reactjs-popup'
import ProfileAttributeForm from '../components/profile-attribute-form'
import Button from '../components/button'
import Table from '../components/table'
import { addTeamMemberAttributes, getTeamMemberAttributes, modifyMemberAttribute, deleteMemberAttribute } from '../lib/profiles-api'
import { addTeamMemberAttributes, getTeamMemberAttributes, modifyAttribute, deleteAttribute } from '../lib/profiles-api'
import theme from '../styles/theme'

export default class TeamEditProfile extends Component {
Expand Down Expand Up @@ -161,7 +161,7 @@ export default class TeamEditProfile extends Component {
<ProfileAttributeForm
initialValues={this.state.rowToModify}
onSubmit={async (attribute) => {
await modifyMemberAttribute(attribute.id, attribute)
await modifyAttribute(attribute.id, attribute)
this.setState({ isModifying: false })
return this.getAttributes()
}}
Expand Down Expand Up @@ -196,7 +196,7 @@ export default class TeamEditProfile extends Component {
? <>
<Button variant='danger' onClick={
async () => {
await deleteMemberAttribute(this.state.rowToDelete.id)
await deleteAttribute(this.state.rowToDelete.id)
this.setState({ isDeleting: false })
return this.getAttributes()
}
Expand Down

0 comments on commit 8a43037

Please sign in to comment.