app/policies/manifest_policy.rb
Assignment Branch Condition size for debug_user is too high. [19/15] Open
Open
def debug_user
puts "user=#{user.pretty_inspect}"
puts "signer?=#{signer?}"
puts "shares_org?=#{shares_org?}"
puts "authz=#{user.user_org_roles.pretty_inspect}"
- Read upRead up
- Exclude checks
This cop checks that the ABC size of methods is not higher than the configured maximum. The ABC size is based on assignments, branches (method calls), and conditions. See http://c2.com/cgi/wiki?AbcMetric
Line is too long. [96/80] Open
Open
public_manifest? || (user && (owner? || shares_org? || epa_data_download? || shares_state?))
- Exclude checks
Line is too long. [108/80] Open
Open
shared_org_ids.include?(uor.organization_id) && uor.role.tsdf_certifier? && uor.cdx_status == 'Active'
- Exclude checks
Trailing whitespace detected. Open
Open
user.user_org_roles.select do |uor|
- Exclude checks
Missing top-level class documentation comment. Open
Open
class ManifestPolicy < ApplicationPolicy
- Read upRead up
- Exclude checks
This cop checks for missing top-level documentation of classes and modules. Classes with no body are exempt from the check and so are namespace modules - modules that have nothing in their bodies except classes, other modules, or constant definitions.
The documentation requirement is annulled if the class or module has a "#:nodoc:" comment next to it. Likewise, "#:nodoc: all" does the same for all its children.
Example:
# bad
class Person
# ...
end
# good
# Description/Explanation of Person class
class Person
# ...
end