Just in case anyone has passed by in recent days and noticed the Twitter panel on my blog displaying tweets that are, well, inconsistent with my normal tweets, fear not! It seems the geniuses behind the Twitter webpart for the Blogger engine have made a small mistake in the JavaScript variable department.
In short, it appears an undefined variable is somehow inserted into a JSON request URL to Twitter and unsurprisingly, the Tweets of an undefined user are being requested. Surprisingly enough though, someone has actually decided that “undefined” is, for some reason, a sensible enough Twitter username to actually use on what appears to be a fairly active basis.
So here we are; undefined (AKA “Adam” based on his website) has unintentionally hijacked my blog’s Twitter feed! From his recent tweets it seems pretty obvious Adam has received quite a bit of attention from people confused by his sudden appearance on their blog. After all, the Blogger gadget in question is the one Google recommends for redisplaying Twitter feeds so I imagine there are a large number of people, inevitably often not technical, who are wondering what the hell is going on. It’s also clear based on Adam’s tweets he’s having a lot of trouble getting through to Google.
Here’s how to fix it
Easy; get rid of the Blogger gadget. This has happened before and with the issue surfacing again I’m not confident it won’t happen again. So let’s keep it simple and ditch the gadget. Fortunately the folks at Twitter have provided a very nifty mechanism for adding a Profile Widget to your website which is configurable via a browser based UI. Go through the steps, preview the widget then there’s an even an easy option to drop it directly into a Blogger based web log. Problem solved!
For the record
Just in case someone from Google does finally decide to get proactive and fix the problem, here’s the Fiddler trace of what’s going on and where it all goes wrong. I haven’t dug any deeper into the source of the problem but a 404 on the .js in request 13 followed by an undefined variable seems very coincidental: