Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

Minor code cleanup. #13

Merged
merged 1 commit into from

2 participants

Rahul Goma Phulore Matt Revelle
Rahul Goma Phulore

This is just a minor code cleanup. Please merge. Thank you!

Matt Revelle
Owner

Nice catch, thanks!

Matt Revelle mattrepl merged commit 02c7af5 into from
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Jul 12, 2012
  1. Rahul Goma Phulore

    Minor code cleanup.

    missingfaktor authored
This page is out of date. Refresh to see the latest.
Showing with 60 additions and 60 deletions.
  1. +60 −60 src/twitter.clj
120 src/twitter.clj
View
@@ -101,7 +101,7 @@ take any required and optional arguments and call the associated Twitter method.
"api.twitter.com/1/statuses/public_timeline.json"
[]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method friends-timeline
:get
@@ -111,7 +111,7 @@ take any required and optional arguments and call the associated Twitter method.
:max-id
:count
:page]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method user-timeline
:get
@@ -124,7 +124,7 @@ take any required and optional arguments and call the associated Twitter method.
:max-id
:count
:page]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method home-timeline
:get
@@ -136,7 +136,7 @@ take any required and optional arguments and call the associated Twitter method.
:page
:skip-user
:include-entities]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method mentions
:get
@@ -146,56 +146,56 @@ take any required and optional arguments and call the associated Twitter method.
:max-id
:count
:page]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method show-status
:get
"api.twitter.com/1/statuses/show.json"
[:id]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method update-status
:post
"api.twitter.com/1/statuses/update.json"
[:status]
[:in-reply-to-status-id]
- (comp #(:status (:content %)) status-handler))
+ (comp :status :content status-handler))
(def-twitter-method destroy-status
:post
"api.twitter.com/1/statuses/destroy.json"
[:id]
[]
- (comp #(:status (:content %)) status-handler))
+ (comp :status :content status-handler))
(def-twitter-method show-user-by-id
:get
"api.twitter.com/1/users/show.json"
[:user-id]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method show-user-by-name
:get
"api.twitter.com/1/users/show.json"
[:screen-name]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method lookup-users-by-id
:get
"api.twitter.com/1/users/lookup.json"
[:user-id]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method lookup-users-by-name
:get
"api.twitter.com/1/users/lookup.json"
[:screen-name]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method direct-messages
:get
@@ -205,7 +205,7 @@ take any required and optional arguments and call the associated Twitter method.
:max-id
:count
:page]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method sent-direct-messages
:get
@@ -215,7 +215,7 @@ take any required and optional arguments and call the associated Twitter method.
:max-id
:count
:page]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method send-direct-message-to-id
:post
@@ -223,7 +223,7 @@ take any required and optional arguments and call the associated Twitter method.
[:user-id
:text]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method send-direct-message-to-name
:post
@@ -231,42 +231,42 @@ take any required and optional arguments and call the associated Twitter method.
[:screen-name
:text]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method destroy-direct-message
:post
"api.twitter.com/1/direct_messages/destroy.json"
[:id]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method create-friendship-to-id
:post
"api.twitter.com/1/friendships/create.json"
[:user-id]
[:follow]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method create-friendship-to-name
:post
"api.twitter.com/1/friendships/create.json"
[:screen-name]
[:follow]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method destroy-friendship-to-id
:post
"api.twitter.com/1/friendships/destroy.json"
[:user-id]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method destroy-friendship-to-name
:post
"api.twitter.com/1/friendships/destroy.json"
[:screen-name]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method show-friendship-by-ids
:get
@@ -274,7 +274,7 @@ take any required and optional arguments and call the associated Twitter method.
[:source-id
:target-id]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method show-friendship-by-names
:get
@@ -282,63 +282,63 @@ take any required and optional arguments and call the associated Twitter method.
[:source-screen-name
:target-screen-name]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method friends-of-id
:get
"api.twitter.com/1/friends/ids.json"
[:user-id]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method friends-of-name
:get
"api.twitter.com/1/friends/ids.json"
[:screen-name]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method followers-of-id
:get
"api.twitter.com/1/followers/ids.json"
[:user-id]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method followers-of-name
:get
"api.twitter.com/1/followers/ids.json"
[:screen-name]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method verify-credentials
:get
"api.twitter.com/1/account/verify_credentials.json"
[]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method rate-limit-status
:get
"api.twitter.com/1/account/rate_limit_status.json"
[]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method end-session
:post
"api.twitter.com/1/account/end_session.json"
[]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method update-delivery-device
:post
"api.twitter.com/1/account/update_delivery_device.json"
[:device]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method update-profile-colors
:post
@@ -349,7 +349,7 @@ take any required and optional arguments and call the associated Twitter method.
:profile-link-color
:profile-sidebar-fill-color
:profile-sidebar-border-color]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(comment (def-twitter-method update-profile-image
@@ -357,7 +357,7 @@ take any required and optional arguments and call the associated Twitter method.
"api.twitter.com/1/account/update_profile_image.json"
[:image]
[]
- (comp #(:content %) status-handler)))
+ (comp :content status-handler)))
(defn update-profile-image [^String image]
(let [req-uri__9408__auto__ "http://api.twitter.com/1/account/update_profile_image.json"
@@ -371,7 +371,7 @@ take any required and optional arguments and call the associated Twitter method.
*oauth-access-token*
:post
req-uri__9408__auto__))]
- ((comp #(:content %) status-handler)
+ ((comp :content status-handler)
(http/post
req-uri__9408__auto__
:query
@@ -388,7 +388,7 @@ take any required and optional arguments and call the associated Twitter method.
"api.twitter.com/1/account/update_profile_background_image.json"
[:image]
[:title]
- (comp #(:content %) status-handler)))
+ (comp :content status-handler)))
(defn update-profile-background-image [^String image & rest__2570__auto__]
(let [req-uri__2571__auto__
@@ -432,7 +432,7 @@ take any required and optional arguments and call the associated Twitter method.
:post
req-uri__2571__auto__
query-params__2576__auto__))]
- ((comp #(:content %) status-handler)
+ ((comp :content status-handler)
(http/post req-uri__2571__auto__
:query (merge query-params__2576__auto__ oauth-creds__2577__auto__)
:parameters (http/map->params {:use-expect-continue false})
@@ -449,7 +449,7 @@ take any required and optional arguments and call the associated Twitter method.
:url
:location
:description]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method favorites
:get
@@ -457,119 +457,119 @@ take any required and optional arguments and call the associated Twitter method.
[]
[:id
:page]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method create-favorite
:post
"api.twitter.com/1/favorites/create.json"
[:id]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method destroy-favorite
:post
"api.twitter.com/1/favorites/destroy.json"
[:id]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method notifications-follow-by-id
:post
"api.twitter.com/1/notifications/follow.json"
[:user-id]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method notifications-follow-by-name
:post
"api.twitter.com/1/notifications/follow.json"
[:screen-name]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method notifications-leave-by-id
:post
"api.twitter.com/1/notifications/leave.json"
[:user-id]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method notifications-leave-by-name
:post
"api.twitter.com/1/notifications/leave.json"
[:screen-name]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method create-block
:post
"api.twitter.com/1/blocks/create.json"
[:user-id-or-screen-name]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method destroy-block
:post
"api.twitter.com/1/blocks/destroy.json"
[:user-id-or-screen-name]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method block-exists-for-id
:get
"api.twitter.com/1/blocks/exists.json"
[:user-id]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method block-exists-for-name
:get
"api.twitter.com/1/blocks/exists.json"
[:screen-name]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method blocking-users
:get
"api.twitter.com/1/blocks/blocking.json"
[]
[:page]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method blocking-user-ids
:get
"api.twitter.com/1/blocks/blocking/ids.json"
[]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method saved-searches
:get
"api.twitter.com/1/saved_searches.json"
[]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method show-saved-search
:get
"api.twitter.com/1/saved_searches/show.json"
[:id]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method create-saved-search
:post
"api.twitter.com/1/saved_searches/create.json"
[:query]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method destroy-saved-search
:post
"api.twitter.com/1/saved_searches/destroy.json"
[:id]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method users-search
:get
@@ -578,7 +578,7 @@ take any required and optional arguments and call the associated Twitter method.
[:page
:per_page
:include_entities]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method search
:get
@@ -592,21 +592,21 @@ take any required and optional arguments and call the associated Twitter method.
:max-id
:geocode
:show-user]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method trends
:get
"search.twitter.com/trends.json"
[]
[]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method current-trends
:get
"search.twitter.com/trends/current.json"
[]
[:exclude]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method daily-trends
:get
@@ -614,7 +614,7 @@ take any required and optional arguments and call the associated Twitter method.
[]
[:date
:exclude]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(def-twitter-method weekly-trends
:get
@@ -622,7 +622,7 @@ take any required and optional arguments and call the associated Twitter method.
[]
[:date
:exclude]
- (comp #(:content %) status-handler))
+ (comp :content status-handler))
(defn status-handler
"Handle the various HTTP status codes that may be returned when accessing
Something went wrong with that request. Please try again.