Skip to content

How to call method with callPromise with applyOptions? #89

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
phanchanra opened this issue Dec 28, 2022 · 1 comment
Open

How to call method with callPromise with applyOptions? #89

phanchanra opened this issue Dec 28, 2022 · 1 comment

Comments

@phanchanra
Copy link

How can we use method with callPromise applyOption not to retry

applyOptions: {
    noRetry: true, // <-- Tell Meteor not to retry
},

this is method on server

export const journal = new ValidatedMethod({
  name: 'app.journa',
  mixins: [CallPromiseMixin],
  applyOptions: {
    noRetry: true, // <-- Tell Meteor not to retry
  },
  validate: null,
  async run() {
   // code here
  }
})

this is client call

journal.callPromise()
    .then(res => {      
      console.log('res', res)
    }).catch(err => {
      console.log('err', err)
    })
  },

notRetry working with callPromise or Meteor.apply

@fracz
Copy link

fracz commented Jan 2, 2023

I believe this issue should be reported to https://github.com/Didericis/callpromise-mixin

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants