Twitter - oauth gem - not getting callback

I redirect the user of my application to Twitter for oauth style
authentication using my app’s request_token.

The user is able to enter username and password on Twitter’s page BUT
then, instead of calling back my application, Twitter displays a page


You’ve successfully granted access to MyAppName!

Simply return to MyAppName and enter the following PIN to complete the
process. 123456

Why is this happening? Can anyone shed some light?

I have set the callback url in my app’s settings.

Any help greatly appreciated.