Sha256: 0ee0369e8972d9070d0ded3dc089c5021589b12daf6b706d1dc5cbab9c7466ee

Contents?: true

Size: 357 Bytes

Versions: 5

Compression:

Stored size: 357 Bytes

Contents

module Githu3

  class Team < Githu3::Resource
    
    has_many :members, :class_name => :user
    has_many :repos
    
    def to_s
      name
    end
    
    def member?(user_login)
      begin
        _client.conn.get("/teams/#{id}/members/#{user_login}").status == 204
      rescue Githu3::NotFound
        false
      end
    end
        
  end

end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
githu3-0.0.8 lib/githu3/team.rb
githu3-0.0.7 lib/githu3/team.rb
githu3-0.0.6 lib/githu3/team.rb
githu3-0.0.5 lib/githu3/team.rb
githu3-0.0.4 lib/githu3/team.rb