Showing 35 of 49 total issues
Method initialize
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def initialize(from, to, algorithm, all=false, types = nil, dir = "all" )
Method return_result
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def return_result(response, code, body, parsed, path, query_body)
Method add_relationship_to_index
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def add_relationship_to_index(index, key, value, id, unique = false)
Method handle_4xx_500_response
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def handle_4xx_500_response(response, code, body, path, query_body)
Method find_geometries_in_bbox
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def find_geometries_in_bbox(layer, minx, maxx, miny, maxy)
Method create_unique
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def self.create_unique(index, key, value, props = nil, db = Neography::Rest.new)
Method batch_find_geometries_in_bbox
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def batch_find_geometries_in_bbox(layer, minx, maxx, miny, maxy)
Method get_path
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def get_path(from, to, relationships, depth = 1, algorithm = "shortestPath")
Method remove_from_index_path
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def remove_from_index_path(klass, index, key_or_id, value_or_id = nil, id = nil)
Method add_node_to_index
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def add_node_to_index(index, key, value, id, unique = false)
Method get_paths
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def get_paths(from, to, relationships, depth = 1, algorithm = "allPaths")
Method initialize
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def initialize(message = nil, code = nil, stacktrace = nil, request = nil, index = 0)
Method batch_add_node_to_index
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def batch_add_node_to_index(index, key, value, id, unique = false)
Method path_options
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def path_options(to, relationships, depth, algorithm, extra_body = {})
Method json
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
Open
def self.json(body)
begin
MultiJson.load(body)
rescue MultiJson::DecodeError, ArgumentError
case
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"