Skip to content

Instantly share code, notes, and snippets.

@csanz
Created June 27, 2011 17:56
Show Gist options
  • Select an option

  • Save csanz/1049373 to your computer and use it in GitHub Desktop.

Select an option

Save csanz/1049373 to your computer and use it in GitHub Desktop.
@return boolean
User.statics.isFollowing(session, user_id)
// Will check if you are already following this user
// find(/username, function(user
// if(user.followersContains(session.user.id)
// return true
@return boolean
User.statics.follow(session, user_id_to_follow)
// Will initiate a follow on a user and return true if no errors found
@return boolean
User.statics.unFollow(session, user_id_to_unfollow)
// Will stop following a given user
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment