mirror of
https://github.com/Qortal/Qortal-Hub.git
synced 2025-06-06 16:36:58 +00:00
Remove unable_ from core error
This commit is contained in:
parent
f73ec1fb3c
commit
b962d01fba
@ -208,7 +208,7 @@ export const AppRating = ({ app, myName, ratingCountPosition = 'right' }) => {
|
||||
type: 'error',
|
||||
message:
|
||||
error?.message ||
|
||||
t('core:message.error.unable_rate', {
|
||||
t('core:message.error.rate', {
|
||||
postProcess: 'capitalizeFirstChar',
|
||||
}),
|
||||
});
|
||||
|
@ -183,7 +183,7 @@ export const AppsPrivate = ({ myName }) => {
|
||||
if (decryptedData?.error) {
|
||||
throw new Error(
|
||||
decryptedData?.error ||
|
||||
t('core:message.error.unable_encrypt_app', {
|
||||
t('core:message.error.encrypt_app', {
|
||||
postProcess: 'capitalizeFirstChar',
|
||||
})
|
||||
);
|
||||
@ -238,7 +238,7 @@ export const AppsPrivate = ({ myName }) => {
|
||||
type: 'error',
|
||||
message:
|
||||
error?.message ||
|
||||
t('core:message.error.unable_publish_app', {
|
||||
t('core:message.error.publish_app', {
|
||||
postProcess: 'capitalizeFirstChar',
|
||||
}),
|
||||
});
|
||||
|
@ -890,7 +890,7 @@ export const ChatGroup = ({
|
||||
);
|
||||
if (res !== true)
|
||||
throw new Error(
|
||||
t('core:message.error.unable_publish_image', {
|
||||
t('core:message.error.publish_image', {
|
||||
postProcess: 'capitalizeFirstChar',
|
||||
})
|
||||
);
|
||||
|
@ -238,7 +238,7 @@ export const Embed = ({ embedLink }) => {
|
||||
return imageFinalUrl;
|
||||
} else {
|
||||
setErrorMsg(
|
||||
t('core:message.error.unable_download_image', {
|
||||
t('core:message.error.download_image', {
|
||||
postProcess: 'capitalizeFirstChar',
|
||||
})
|
||||
);
|
||||
|
@ -69,7 +69,7 @@ export const PollCard = ({
|
||||
type: 'error',
|
||||
message:
|
||||
response?.error ||
|
||||
t('core:message.error.unable_vote', {
|
||||
t('core:message.error.vote', {
|
||||
postProcess: 'capitalizeFirstChar',
|
||||
}),
|
||||
});
|
||||
@ -91,7 +91,7 @@ export const PollCard = ({
|
||||
type: 'error',
|
||||
message:
|
||||
error?.message ||
|
||||
t('core:message.error.unable_vote', {
|
||||
t('core:message.error.vote', {
|
||||
postProcess: 'capitalizeFirstChar',
|
||||
}),
|
||||
});
|
||||
|
@ -70,7 +70,7 @@ export const useHandlePrivateApps = () => {
|
||||
}
|
||||
|
||||
throw new Error(
|
||||
t('core:message.error.unable_fetch_app', {
|
||||
t('core:message.error.fetch_app', {
|
||||
postProcess: 'capitalizeFirstChar',
|
||||
})
|
||||
);
|
||||
@ -249,7 +249,7 @@ export const useHandlePrivateApps = () => {
|
||||
setLoadingStatePrivateApp(
|
||||
`Error! ${
|
||||
error?.message ||
|
||||
t('core:message.error.unable_build_app', {
|
||||
t('core:message.error.build_app', {
|
||||
postProcess: 'capitalizeFirstChar',
|
||||
})
|
||||
}`
|
||||
@ -262,7 +262,7 @@ export const useHandlePrivateApps = () => {
|
||||
type: 'error',
|
||||
message:
|
||||
error?.message ||
|
||||
t('core:message.error.unable_fetch_app', {
|
||||
t('core:message.error.fetch_app', {
|
||||
postProcess: 'capitalizeFirstChar',
|
||||
}),
|
||||
});
|
||||
|
@ -174,12 +174,19 @@
|
||||
"error": {
|
||||
"address_not_found": "your address was not found",
|
||||
"app_need_name": "your app needs a name",
|
||||
"build_app": "unable to build private app",
|
||||
"decrypt_app": "unable to decrypt private app'",
|
||||
"download_image": "unable to download IMAGE. Please try again later by clicking the refresh button",
|
||||
"download_private_app": "unable to download private app",
|
||||
"encrypt_app": "unable to encrypt app. App not published'",
|
||||
"fetch_app": "unable to fetch app",
|
||||
"fetch_publish": "unable to fetch publish",
|
||||
"file_too_large": "file {{ filename }} is too large. Max size allowed is {{ size }} MB.",
|
||||
"generic": "an error occurred",
|
||||
"invalid_base64": "invalid base64 data",
|
||||
"invalid_embed_link": "invalid embed link",
|
||||
"invalid_poll_embed_link_name": "invalid poll embed link. Missing name.",
|
||||
"invalid_image_embed_link_name": "invalid image embed link. Missing param.",
|
||||
"invalid_poll_embed_link_name": "invalid poll embed link. Missing name.",
|
||||
"invalid_signature": "invalid signature",
|
||||
"invalid_theme_format": "invalid theme format",
|
||||
"invalid_zip": "invalid zip",
|
||||
@ -193,21 +200,13 @@
|
||||
"password_not_matching": "password fields do not match!",
|
||||
"password_wrong": "unable to authenticate. Wrong password",
|
||||
"publish_app": "unable to publish app",
|
||||
"publish_image": "unable to publish image",
|
||||
"rate": "unable to rate",
|
||||
"rating_option": "cannot find rating option",
|
||||
"save_qdn": "unable to save to QDN",
|
||||
"send_failed": "failed to send",
|
||||
"unable_build_app": "unable to build private app",
|
||||
"unable_download_image": "unable to download IMAGE. Please try again later by clicking the refresh button",
|
||||
"unable_download_private_app": "unable to download private app",
|
||||
"unable_decrypt_app": "unable to decrypt private app'",
|
||||
"unable_encrypt_app": "unable to encrypt app. App not published'",
|
||||
"unable_fetch_app": "unable to fetch app",
|
||||
"unable_fetch_publish": "unable to fetch publish",
|
||||
"unable_publish_app": "unable to publish app",
|
||||
"unable_publish_image": "unable to publish image",
|
||||
"unable_rate": "unable to rate",
|
||||
"unable_vote": "unable to vote",
|
||||
"update_failed": "failed to update"
|
||||
"update_failed": "failed to update",
|
||||
"vote": "unable to vote"
|
||||
},
|
||||
"generic": {
|
||||
"already_voted": "you've already voted.",
|
||||
|
@ -112,6 +112,7 @@
|
||||
"descrypt_wallet": "error decrypting wallet {{ :errorMessage }}",
|
||||
"description_required": "please provide a description",
|
||||
"group_info": "cannot access group information",
|
||||
"group_join": "failed to join the group",
|
||||
"group_promotion": "error publishing the promotion. Please try again",
|
||||
"group_secret_key": "cannot get group secret key",
|
||||
"name_required": "please provide a name",
|
||||
|
@ -2191,7 +2191,12 @@ export const joinGroup = async (data, isFromExtension) => {
|
||||
const resJoinGroup = await joinGroupFunc({ groupId });
|
||||
return resJoinGroup;
|
||||
} catch (error) {
|
||||
throw new Error(error?.message || 'Failed to join the group.');
|
||||
throw new Error(
|
||||
error?.message ||
|
||||
i18n.t('group:message.error.group_join', {
|
||||
postProcess: 'capitalizeFirstChar',
|
||||
})
|
||||
);
|
||||
}
|
||||
} else {
|
||||
throw new Error('User declined to join group'); // TODO translate
|
||||
@ -2304,7 +2309,12 @@ export const deployAt = async (data, isFromExtension) => {
|
||||
);
|
||||
return resDeployAt;
|
||||
} catch (error) {
|
||||
throw new Error(error?.message || 'Failed to join the group.');
|
||||
throw new Error(
|
||||
error?.message ||
|
||||
i18n.t('group:message.error.group_join', {
|
||||
postProcess: 'capitalizeFirstChar',
|
||||
})
|
||||
);
|
||||
}
|
||||
};
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user