Dup subscriptions not allowed
This commit is contained in:
parent
621cf4e2ad
commit
e703057377
4 changed files with 13 additions and 3 deletions
|
|
@ -35,7 +35,9 @@ class SubscriptionEditor extends React.Component {
|
|||
if (authenticated) {
|
||||
Meteor.call(methodToCall, doc, (error, subscriptionId) => {
|
||||
if (error) {
|
||||
Bert.alert(error.reason, 'danger');
|
||||
if (error.reason && error.reason.reason) {
|
||||
Bert.alert(t(error.reason.reason), 'danger');
|
||||
}
|
||||
} else {
|
||||
const confirmation = existingSubscription ? t('Zona actualizada') : t('Zona añadida');
|
||||
Bert.alert(confirmation, 'success');
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue