Fix account notes not being displayed (#34166)

This commit is contained in:
Claire 2025-03-18 11:32:35 +01:00 committed by GitHub
parent 6bce43cdb8
commit 9d5cbbbf0f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 11 additions and 12 deletions

View file

@ -4,14 +4,14 @@ import { submitAccountNote } from 'mastodon/actions/account_notes';
import AccountNote from '../components/account_note';
const mapStateToProps = (state, { account }) => ({
value: account.getIn(['relationship', 'note']),
const mapStateToProps = (state, { accountId }) => ({
value: state.relationships.getIn([accountId, 'note']),
});
const mapDispatchToProps = (dispatch, { account }) => ({
const mapDispatchToProps = (dispatch, { accountId }) => ({
onSave (value) {
dispatch(submitAccountNote({ accountId: account.get('id'), note: value }));
dispatch(submitAccountNote({ accountId: accountId, note: value }));
},
});