diff options
author | Douglas Barbosa Alexandre <dbalexandre@gmail.com> | 2017-04-24 19:04:39 -0300 |
---|---|---|
committer | Douglas Barbosa Alexandre <dbalexandre@gmail.com> | 2017-04-24 19:04:39 -0300 |
commit | 9bdde5796a6e6ed56a29865b19a910bdea5d078e (patch) | |
tree | e7d4a4754278aa1898b998c669df2e8e8b84d643 /lib | |
parent | 2b7328c3171661ce8e4a5b3b840ff5f3df19d3e0 (diff) | |
download | gitlab-ce-9bdde5796a6e6ed56a29865b19a910bdea5d078e.tar.gz |
Add Github::Representation::Base#id
Diffstat (limited to 'lib')
-rw-r--r-- | lib/github/representation/base.rb | 4 | ||||
-rw-r--r-- | lib/github/representation/repo.rb | 3 | ||||
-rw-r--r-- | lib/github/representation/user.rb | 4 |
3 files changed, 4 insertions, 7 deletions
diff --git a/lib/github/representation/base.rb b/lib/github/representation/base.rb index 385e62ae99d..f26bdbdd546 100644 --- a/lib/github/representation/base.rb +++ b/lib/github/representation/base.rb @@ -6,6 +6,10 @@ module Github @options = options end + def id + raw['id'] + end + def url raw['url'] end diff --git a/lib/github/representation/repo.rb b/lib/github/representation/repo.rb index b9cae43450e..6938aa7db05 100644 --- a/lib/github/representation/repo.rb +++ b/lib/github/representation/repo.rb @@ -1,9 +1,6 @@ module Github module Representation class Repo < Representation::Base - def id - raw['id'] - end end end end diff --git a/lib/github/representation/user.rb b/lib/github/representation/user.rb index 79758555319..18591380e25 100644 --- a/lib/github/representation/user.rb +++ b/lib/github/representation/user.rb @@ -1,10 +1,6 @@ module Github module Representation class User < Representation::Base - def id - raw['id'] - end - def email return @email if defined?(@email) |