Class: Bundler::Security::Voting::RemotePolicy
- Inherits:
-
Struct
- Object
- Struct
- Bundler::Security::Voting::RemotePolicy
- Defined in:
- lib/bundler/security/voting/remote_policy.rb
Overview
Remote policy settings from Coditsu
Instance Attribute Summary collapse
-
#threshold ⇒ Object
Returns the value of attribute threshold.
-
#type ⇒ Object
Returns the value of attribute type.
Instance Method Summary collapse
-
#approved ⇒ Integer
How many time gem was marked as safe.
-
#rejected ⇒ Integer
How many time gem was marked as malicious.
Instance Attribute Details
#threshold ⇒ Object
Returns the value of attribute threshold
7 8 9 |
# File 'lib/bundler/security/voting/remote_policy.rb', line 7 def threshold @threshold end |
#type ⇒ Object
Returns the value of attribute type
7 8 9 |
# File 'lib/bundler/security/voting/remote_policy.rb', line 7 def type @type end |
Instance Method Details
#approved ⇒ Integer
How many time gem was marked as safe
11 12 13 |
# File 'lib/bundler/security/voting/remote_policy.rb', line 11 def approved threshold['up'].to_i end |
#rejected ⇒ Integer
How many time gem was marked as malicious
18 19 20 |
# File 'lib/bundler/security/voting/remote_policy.rb', line 18 def rejected threshold['down'].to_i end |