Jump to content

canSubscribeBotAsync don`t works


Barabus
 Share

Recommended Posts

        FBInstant.initializeAsync().then(function()
        {
            FBInstant.startGameAsync().then(function()
            {
                FBInstant.player.canSubscribeBotAsync().then(function(can_subscribe)
                {
                    if (can_subscribe)
                    {
                        console.log("We can subscribe for bot.");
                        FBInstant.player.subscribeBotAsync().then(function()
                        {
                            console.log("We are successfully subscribed for bot.");
                        }).catch(function (e)
                        {
                            console.log("Subscribtion for bot has been failed, error: " + e.message)
                        });
                    }
                    else
                    {
                        console.log("We can not subscribe for bot, and have no error.")
                    }
                }).catch(function (e)
                {
                  console.log("We can not subscribe for bot: " + e.message)
                });
            });
        });

The app always returns "We can not subscribe for bot, and have no error." What is wrong in this code?

Link to comment
Share on other sites

@Barabus Well, you are calling canSubscribeBotAsync to check if that user can subscribe to the bot. It looks like this player cannot, that is it. We do not list all the cases this might happen, as it is subject to change, but you can assume that it returns the correct value.

Link to comment
Share on other sites

  • 3 months later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...