Method show
has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring.
def show
unless request.xhr?
render('empty') and return if @project.is_empty?
@tree = @tree / @path if @path.present?
@commit = @branch.present? ? @branch.commit() : @project.repo.log(@treeish, @path, max_count: 1).first
Method archive
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring.
def archive
format, @treeish = params[:format], params[:treeish]
raise Grit::NoSuchPathError unless @treeish =~ /^
@treeish !~ /[\s]+/ &&
format =~ /\A(zip|tar\.gz)\z/
Method get_sha1_of_archive
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
def get_sha1_of_archive
format, @treeish = params[:format], params[:treeish]
raise Grit::NoSuchPathError unless @treeish =~ /^
@treeish !~ /[\s]+/ &&
format =~ /\A(zip|tar\.gz)\z/
There are no issues that match your filters.