Refactor twitter_api.rb and user.rb