facebook v4 plugin

I have just upgraded to facebook v4 plugin. On iOS the app logs into facebook ok, but “invite friends” (showDialog request) does not work, the invite box does not come up, instead facebook is displayed for one second then control immediately returns to app.

this is the code;

local fbListener = function( event )

    if ( “session” == event.type ) then

        if ( “login” == event.phase ) then

            facebook.showDialog( “requests”, { message=“You should download this game!” } )

        end

    elseif ( “dialog” == event.type ) then

        print( event.response )

    end

end

function inviteFriends()

    facebook.login( fbListener )

    return true

end

On Android it all works perfectly. I have a feeling it might be how I set things up in Facebook, but I just can’t find the problem.

Are you getting any errors in your console log?

Yes…

Nov  1 12:43:18 Janes-iPad Facebook[1357] <Warning>: Unbalanced calls to begin/end appearance transitions for <FBTopBarAndContentViewController: 0x12edc40b0>.

Nov  1 12:43:19 Janes-iPad APP[1313] <Warning>: FBSDKLog: starting with Graph API v2.4, GET requests for /me should contain an explicit “fields” parameter

Nov  1 12:43:19 Janes-iPad APP[1313] <Warning>: FBSDKLog: starting with Graph API v2.4, GET requests for /oauth/access_token should contain an explicit “fields” parameter

Nov  1 12:43:19 Janes-iPad APP[1313] <Warning>: FBSDKLog: starting with Graph API v2.4, GET requests for /me/permissions should contain an explicit “fields” parameter

Nov  1 12:43:19 Janes-iPad APP[1313] <Error>: Could not successfully update network info during initialization.

Nov  1 12:43:19 Janes-iPad locationd[55] <Notice>: ERROR: co.DDD.APP.rel is depending on legacy on-demand authorization, which is not supported for new apps

Hi prographodeveloper,

No need to worry about your set up being wrong on iOS. We discovered an issue on iOS where facebook.showDialog( “requests”, {} ) will fail unless you provide a to parameter in the options table.

While we work on fixing this, you can work around your issue by modifying your showDialog call as follows:

facebook.showDialog( "requests", { message="You should download this game!", to="" } )

thx will try this now.

Hi prographodeveloper,

This issue on iOS has been fixed. You should be safe to remove the dummy to field now.

Are you getting any errors in your console log?

Yes…

Nov  1 12:43:18 Janes-iPad Facebook[1357] <Warning>: Unbalanced calls to begin/end appearance transitions for <FBTopBarAndContentViewController: 0x12edc40b0>.

Nov  1 12:43:19 Janes-iPad APP[1313] <Warning>: FBSDKLog: starting with Graph API v2.4, GET requests for /me should contain an explicit “fields” parameter

Nov  1 12:43:19 Janes-iPad APP[1313] <Warning>: FBSDKLog: starting with Graph API v2.4, GET requests for /oauth/access_token should contain an explicit “fields” parameter

Nov  1 12:43:19 Janes-iPad APP[1313] <Warning>: FBSDKLog: starting with Graph API v2.4, GET requests for /me/permissions should contain an explicit “fields” parameter

Nov  1 12:43:19 Janes-iPad APP[1313] <Error>: Could not successfully update network info during initialization.

Nov  1 12:43:19 Janes-iPad locationd[55] <Notice>: ERROR: co.DDD.APP.rel is depending on legacy on-demand authorization, which is not supported for new apps

Hi prographodeveloper,

No need to worry about your set up being wrong on iOS. We discovered an issue on iOS where facebook.showDialog( “requests”, {} ) will fail unless you provide a to parameter in the options table.

While we work on fixing this, you can work around your issue by modifying your showDialog call as follows:

facebook.showDialog( "requests", { message="You should download this game!", to="" } )

thx will try this now.

Hi prographodeveloper,

This issue on iOS has been fixed. You should be safe to remove the dummy to field now.