mirror of
https://github.com/ecency/ecency-mobile.git
synced 2025-01-03 03:25:24 +03:00
fix error messages
This commit is contained in:
parent
b0589aff8b
commit
c751a1aae1
@ -164,7 +164,7 @@ class PostDropdownContainer extends PureComponent {
|
||||
),
|
||||
);
|
||||
} else {
|
||||
if (error && error.error_description.split(':')[1].includes('wait to transact')) {
|
||||
if (error && error.jse_shortmsg.split(':')[1].includes('wait to transact')) {
|
||||
//when RC is not enough, offer boosting account
|
||||
Alert.alert(
|
||||
intl.formatMessage({
|
||||
|
@ -104,8 +104,8 @@ class UpvoteView extends Component {
|
||||
console.log(err);
|
||||
if (
|
||||
err &&
|
||||
err.error_description.split(':')[1] &&
|
||||
err.error_description.split(':')[1].includes('wait to transact')
|
||||
err.jse_shortmsg.split(':')[1] &&
|
||||
err.jse_shortmsg.split(':')[1].includes('wait to transact')
|
||||
) {
|
||||
//when RC is not enough, offer boosting account
|
||||
Alert.alert(
|
||||
@ -131,19 +131,19 @@ class UpvoteView extends Component {
|
||||
});
|
||||
} else {
|
||||
//when voting with same percent or other errors
|
||||
if (err.error_description.indexOf(':') > 0) {
|
||||
if (err.jse_shortmsg.indexOf(':') > 0) {
|
||||
Alert.alert(
|
||||
intl.formatMessage({
|
||||
id: 'alert.fail',
|
||||
}),
|
||||
err.error_description.split(':')[1],
|
||||
err.jse_shortmsg.split(':')[1],
|
||||
);
|
||||
} else {
|
||||
Alert.alert(
|
||||
intl.formatMessage({
|
||||
id: 'alert.fail',
|
||||
}),
|
||||
err.error_description,
|
||||
err.jse_shortmsg,
|
||||
);
|
||||
}
|
||||
this.setState({
|
||||
|
@ -184,10 +184,7 @@ class ProfileContainer extends Component {
|
||||
});
|
||||
console.log(error);
|
||||
if (error) {
|
||||
if (
|
||||
error.error_description &&
|
||||
error.error_description.split(':')[1].includes('wait to transact')
|
||||
) {
|
||||
if (error.jse_shortmsg && error.jse_shortmsg.split(':')[1].includes('wait to transact')) {
|
||||
//when RC is not enough, offer boosting account
|
||||
Alert.alert(
|
||||
intl.formatMessage({
|
||||
|
@ -397,7 +397,7 @@ class EditorContainer extends Component {
|
||||
_handleSubmitFailure = (error) => {
|
||||
const { intl } = this.props;
|
||||
console.log(error);
|
||||
if (error && error.error_description.split(':')[1].includes('wait to transact')) {
|
||||
if (error && error.jse_shortmsg.split(':')[1].includes('wait to transact')) {
|
||||
//when RC is not enough, offer boosting account
|
||||
Alert.alert(
|
||||
intl.formatMessage({
|
||||
|
Loading…
Reference in New Issue
Block a user