mirror of
https://github.com/wassname/talk.git
synced 2026-07-11 16:39:49 +08:00
Merge pull request #1081 from PepeFranco/ReadersNotifications
Added notifications when flagging failed
This commit is contained in:
@@ -8,6 +8,8 @@ import ClickOutside from 'coral-framework/components/ClickOutside';
|
||||
import cn from 'classnames';
|
||||
import styles from './styles.css';
|
||||
|
||||
import {getErrorMessages} from 'coral-framework/utils';
|
||||
|
||||
const name = 'talk-plugin-flags';
|
||||
|
||||
export default class FlagButton extends Component {
|
||||
@@ -99,6 +101,7 @@ export default class FlagButton extends Component {
|
||||
}
|
||||
})
|
||||
.catch((err) => {
|
||||
this.props.notify('error', getErrorMessages(err));
|
||||
console.error(err);
|
||||
});
|
||||
} else {
|
||||
@@ -109,6 +112,7 @@ export default class FlagButton extends Component {
|
||||
}
|
||||
})
|
||||
.catch((err) => {
|
||||
this.props.notify('error', getErrorMessages(err));
|
||||
console.error(err);
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user