Showing 201 of 591 total issues
Function JsonPropertyDecorator
has 76 lines of code (exceeds 25 allowed). Consider refactoring. Open
var JsonPropertyDecorator = (function (_ResourceDecorator) {
function JsonPropertyDecorator(loadedDataEndpointFactory, embeddedPropertyTransformerFactory, promiseEndpointFactory, name, path, value, options) {
_classCallCheck(this, JsonPropertyDecorator);
_get(Object.getPrototypeOf(JsonPropertyDecorator.prototype), "constructor", this).call(this, name);
Function ListRelationshipDescription
has a Cognitive Complexity of 20 (exceeds 5 allowed). Consider refactoring. Open
var ListRelationshipDescription = (function (_RelationshipDescription) {
function ListRelationshipDescription(relationshipInitializerFactory, resourceMapperFactory, resourceSerializerFactory, inflector, singleRelationshipDescriptionFactory, ListResource, primaryResourceTransformerFactory, embeddedRelationshipTransformerFactory, individualFromListTransformerFactory, createResourceTransformerFactory, resolvedEndpointFactory, loadedDataEndpointFactory, templatedUrlFromUrlFactory, templatedUrlFactory, name, ResourceClass, initialValues) {
_classCallCheck(this, ListRelationshipDescription);
_get(Object.getPrototypeOf(ListRelationshipDescription.prototype), "constructor", this).call(this, relationshipInitializerFactory, resourceMapperFactory, resourceSerializerFactory, inflector, name, ResourceClass, initialValues);
- 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"
Further reading
Function ResolvedEndpoint
has 66 lines of code (exceeds 25 allowed). Consider refactoring. Open
var ResolvedEndpoint = (function (_Endpoint) {
function ResolvedEndpoint(Promise, transport, templatedUrl) {
var _this = this;
var resourceTransformers = arguments[3] === undefined ? [] : arguments[3];
Resource
has 23 functions (exceeds 20 allowed). Consider refactoring. Open
export default class Resource extends DataWrapper {
constructor(responseData) {
super(responseData);
if (!responseData) {
this.emptyData();
Resource
has 23 functions (exceeds 20 allowed). Consider refactoring. Open
export default class Resource extends DataWrapper {
constructor(responseData) {
super(responseData);
if (!responseData) {
this.emptyData();
Function ResourceMapper
has a Cognitive Complexity of 18 (exceeds 5 allowed). Consider refactoring. Open
var ResourceMapper = (function (_Mapper) {
function ResourceMapper(templatedUrlFromUrlFactory, resourceBuilderFactory, primaryResourceBuilderFactory, primaryResourceTransformerFactory, transport, response, relationshipDescription) {
var endpoint = arguments[7] === undefined ? null : arguments[7];
var useErrors = arguments[8] === undefined ? false : arguments[8];
- 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"
Further reading
Function TemplatedUrl
has 59 lines of code (exceeds 25 allowed). Consider refactoring. Open
var TemplatedUrl = (function () {
function TemplatedUrl(uriTemplate) {
var uriParams = arguments[1] === undefined ? {} : arguments[1];
_classCallCheck(this, TemplatedUrl);
Function Endpoint
has 59 lines of code (exceeds 25 allowed). Consider refactoring. Open
var Endpoint = (function () {
function Endpoint() {
_classCallCheck(this, Endpoint);
}
Function mapNestedRelationships
has 57 lines of code (exceeds 25 allowed). Consider refactoring. Open
value: function mapNestedRelationships() {
var _this = this;
// add mappings for list resource
_get(Object.getPrototypeOf(ListResourceMapper.prototype), "mapNestedRelationships", this).call(this);
Function mapNestedRelationships
has 57 lines of code (exceeds 25 allowed). Consider refactoring. Open
mapNestedRelationships: function() {
var $__16 = this;
$traceurRuntime.superGet(this, $ListResourceMapper.prototype, "mapNestedRelationships").call(this);
this.resource = this.mapped;
var manyResourceMapper = this.manyResourceMapperFactory(this.transport, this.resource.pathGet("$.data"), this.relationshipDescription);
Function Endpoint
has a Cognitive Complexity of 17 (exceeds 5 allowed). Consider refactoring. Open
var Endpoint = (function () {
function Endpoint() {
_classCallCheck(this, Endpoint);
}
- 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"
Further reading
Function trace
has 55 lines of code (exceeds 25 allowed). Consider refactoring. Open
trace: function(expr, val, path) {
function addRet(elems) {
ret = ret.concat(elems);
}
if (!expr.length) {
Function ListRelationshipDescription
has 17 arguments (exceeds 4 allowed). Consider refactoring. Open
function ListRelationshipDescription(relationshipInitializerFactory, resourceMapperFactory, resourceSerializerFactory, inflector, singleRelationshipDescriptionFactory, ListResource, primaryResourceTransformerFactory, embeddedRelationshipTransformerFactory, individualFromListTransformerFactory, createResourceTransformerFactory, resolvedEndpointFactory, loadedDataEndpointFactory, templatedUrlFromUrlFactory, templatedUrlFactory, name, ResourceClass, initialValues) {
Function ListRelationshipDescription
has 17 arguments (exceeds 4 allowed). Consider refactoring. Open
var ListRelationshipDescription = function ListRelationshipDescription(relationshipInitializerFactory, resourceMapperFactory, resourceSerializerFactory, inflector, singleRelationshipDescriptionFactory, ListResource, primaryResourceTransformerFactory, embeddedRelationshipTransformerFactory, individualFromListTransformerFactory, createResourceTransformerFactory, resolvedEndpointFactory, loadedDataEndpointFactory, templatedUrlFromUrlFactory, templatedUrlFactory, name, ResourceClass, initialValues) {
Function RelationshipUtilities
has a Cognitive Complexity of 16 (exceeds 5 allowed). Consider refactoring. Open
var RelationshipUtilities = (function () {
function RelationshipUtilities() {
_classCallCheck(this, RelationshipUtilities);
}
- 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"
Further reading
Function ResourceBuilder
has a Cognitive Complexity of 16 (exceeds 5 allowed). Consider refactoring. Open
var ResourceBuilder = (function () {
function ResourceBuilder(templatedUrlFromUrlFactory, resolvedEndpointFactory, throwErrorTransformerFactory, createResourceTransformerFactory, transport, response, primaryResourceTransformer, ResourceClass, relationshipDescription) {
_classCallCheck(this, ResourceBuilder);
this.transport = transport;
- 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"
Further reading
Function UrlHelper
has 51 lines of code (exceeds 25 allowed). Consider refactoring. Open
var UrlHelper = (function () {
function UrlHelper(baseUrl) {
_classCallCheck(this, UrlHelper);
if (this.isFullUrl(baseUrl)) {
Function IndividualFromListTransformer
has 49 lines of code (exceeds 25 allowed). Consider refactoring. Open
var IndividualFromListTransformer = (function (_ResourceTransformer) {
function IndividualFromListTransformer(templatedUrlFactory, relationshipName, uriParams) {
_classCallCheck(this, IndividualFromListTransformer);
_get(Object.getPrototypeOf(IndividualFromListTransformer.prototype), "constructor", this).call(this);
Function ResourceMapper
has 48 lines of code (exceeds 25 allowed). Consider refactoring. Open
var ResourceMapper = (function (_Mapper) {
function ResourceMapper(templatedUrlFromUrlFactory, resourceBuilderFactory, primaryResourceBuilderFactory, primaryResourceTransformerFactory, transport, response, relationshipDescription) {
var endpoint = arguments[7] === undefined ? null : arguments[7];
var useErrors = arguments[8] === undefined ? false : arguments[8];
Function ResourceBuilder
has 48 lines of code (exceeds 25 allowed). Consider refactoring. Open
var ResourceBuilder = (function () {
function ResourceBuilder(templatedUrlFromUrlFactory, resolvedEndpointFactory, throwErrorTransformerFactory, createResourceTransformerFactory, transport, response, primaryResourceTransformer, ResourceClass, relationshipDescription) {
_classCallCheck(this, ResourceBuilder);
this.transport = transport;