issue #5592: fix bugs of dialog callback
issue #5592: fix some bugs
Merge pull request #19 from joshuastray/plugin_fb

issue #5592: fix bugs of dialog callback