AvianFlu/ntwitter — Issue #28: showUser doesn't differentiate between screen_names and ids correctly
Author: cpetzold
Created: 2012-02-08 23:01:09+00:00
State: open

There's no real way to do this actually, since just numbers is also a valid twitter username: http://twitter.com/1337

Perhaps a change that lets you specify if you're using id's or screen_names?

The other fix, if you still wanted to remain optimistic that most usernames aren't numbers (or don't start with numbers), would be to use a regex to check if it's a line instead of parseInt, because parseInt('20string') == 20.

https://github.com/AvianFlu/ntwitter/blob/master/lib/twitter.js#L582