Showing 481 of 922 total issues
Function initComponent
has 80 lines of code (exceeds 25 allowed). Consider refactoring. Open
initComponent: function ()
{
var config = {};
Ext.Object.merge(config, {
Function initComponent
has 79 lines of code (exceeds 25 allowed). Consider refactoring. Open
initComponent: function () {
/**
* @event itemDeselect
* Fires if a record was deselected within the grid.
Method testCreateProject
has 78 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function testCreateProject()
{
$client = static::makeClient(true);
$file = __DIR__.'/../../UploadedFileBundle/Tests/Fixtures/files/uploadtest.png';
Function getAssociatedStore
has a Cognitive Complexity of 22 (exceeds 5 allowed). Consider refactoring. Open
getAssociatedStore: function (inverseRecord, options, scope, records, isComplete) {
// Consider the Comment entity with a ticketId to a Ticket entity. The Comment
// is on the left (the FK holder's side) so we are implementing the guts of
// the comments() method to load the Store of Comment entities. This trek
// begins from a Ticket (inverseRecord).
- 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 initComponent
has 76 lines of code (exceeds 25 allowed). Consider refactoring. Open
initComponent: function ()
{
this.dockedItems = [
{
xtype: 'toolbar',
Function initComponent
has 75 lines of code (exceeds 25 allowed). Consider refactoring. Open
initComponent: function ()
{
/**
* Create the "add stock" button
*/
Function make
has 74 lines of code (exceeds 25 allowed). Consider refactoring. Open
make: function (node, model, prefix, callback)
{
var newNode,i ,j, childNode, associationAlreadyProcessed;
if (!prefix) {
Function hashpw
has 73 lines of code (exceeds 25 allowed). Consider refactoring. Open
bCrypt.prototype.hashpw = function(password, salt, callback, progress) {
var real_salt;
var passwordb = [];
var saltb = [];
var hashed = [];
Function initComponent
has 73 lines of code (exceeds 25 allowed). Consider refactoring. Open
initComponent: function ()
{
this.operatorStore = Ext.create("PartKeepr.Data.store.OperatorStore");
this.nameField = Ext.create("Ext.form.field.Text", {
Function formatParameter
has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring. Open
formatParameter: function (partParameter) {
var minSiPrefix = "", siPrefix = "", maxSiPrefix = "", unit = "", minValue = "", maxValue = "", value = "",
minMaxCombined = "";
if (partParameter.get("valueType") === "string")
- 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 findUndeletableUsages
has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring. Open
public function findUndeletableUsages($entity)
{
$realClassName = $this->em->getClassMetadata(get_class($entity))->name;
$meta = $this->em->getMetadataFactory()->getAllMetadata();
- 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 onDataLoaded
has 72 lines of code (exceeds 25 allowed). Consider refactoring. Open
onDataLoaded: function ()
{
if (this.searchStore.getCount() === 0) {
return;
}
Function startSearch
has 72 lines of code (exceeds 25 allowed). Consider refactoring. Open
startSearch: function ()
{
var me = this,
store = me.store,
searchValue = me.getValue(),
Function initComponent
has 71 lines of code (exceeds 25 allowed). Consider refactoring. Open
initComponent: function () {
var target, menuItemIterator;
this.ui = "mainmenu";
Function doSearch
has 71 lines of code (exceeds 25 allowed). Consider refactoring. Open
doSearch: function (searchValue) {
if (typeof searchValue !== "string") {
return;
}
ReportPart
has 25 functions (exceeds 20 allowed). Consider refactoring. Open
class ReportPart extends BaseEntity
{
/**
* @ORM\ManyToOne(targetEntity="PartKeepr\ProjectBundle\Entity\Report",inversedBy="reportParts")
* @Groups({"default"})
Method getConfig
has 70 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function getConfig($config)
{
// Parameter defaults to ensure they exist
$parameters = [
'database_driver' => null,
Function renderCell
has 69 lines of code (exceeds 25 allowed). Consider refactoring. Open
renderCell: function (column, record, recordIndex, rowIndex, columnIndex, out) {
var me = this,
fullIndex,
selModel = me.selectionModel,
cellValues = me.cellValues,
Function onKeyPress
has a Cognitive Complexity of 20 (exceeds 5 allowed). Consider refactoring. Open
onKeyPress: function (e)
{
var hotKeyPressed = false;
var hotKey = PartKeepr.getApplication().getSystemPreference("partkeepr.barcodeScanner.key", "");
- 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 encodeFilters
has a Cognitive Complexity of 20 (exceeds 5 allowed). Consider refactoring. Open
encodeFilters: function (filters)
{
var out = [],
length = filters.length,
i, filter, j;
- 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"