Skip to content
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

error checking #3

Open
stylenclass opened this issue May 5, 2014 · 0 comments
Open

error checking #3

stylenclass opened this issue May 5, 2014 · 0 comments

Comments

@stylenclass
Copy link

blank url for json, eg.
http://deploy.mynaweb.com/asdfasfda/myna.json

would yield false positive, seems like its not being caught by errorCallback

I'm using v2 api by the way.

 Myna.initRemote({
    url: 'http://deploy.mynaweb.com/asdfasfda/myna.json',
    success: function successCallback(client) {
      client.suggest(
        'random-hash',
        function successCallback(variant, firstTimeSuggested) {
          console.log(variant, firstTimeSuggested)
        },
        function errorCallback() {
          // Something went wrong - fall back to a default variant...
        }
      )
    },
    error: function errorCallback() {
      // Myna failed to initialize...
      console.log('error')
    }
  });

Getting a type error on the above code.

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

1 participant