Showing 290 of 611 total issues
Similar blocks of code found in 2 locations. Consider refactoring. Open
}, nodeIsEmptyTextNode: function(t3) {
return e.nodeIsTextNode(t3) && (t3 != null ? t3.data : void 0) === "";
}, nodeIsTextNode: function(t3) {
- Read upRead up
Duplicated Code
Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:
Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.
When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).
Tuning
This issue has a mass of 46.
We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.
The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.
If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.
See codeclimate-duplication
's documentation for more information about tuning the mass threshold in your .codeclimate.yml
.
Refactorings
- Extract Method
- Extract Class
- Form Template Method
- Introduce Null Object
- Pull Up Method
- Pull Up Field
- Substitute Algorithm
Further Reading
- Don't Repeat Yourself on the C2 Wiki
- Duplicated Code on SourceMaking
- Refactoring: Improving the Design of Existing Code by Martin Fowler. Duplicated Code, p76
Similar blocks of code found in 2 locations. Consider refactoring. Open
return t2(i, n2), i.textForAttachmentWithAttributes = function(t3, n3) {
var i2;
return i2 = new e.AttachmentPiece(t3, n3), new this([i2]);
}, i.textForStringWithAttributes = function(t3, n3) {
- Read upRead up
Duplicated Code
Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:
Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.
When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).
Tuning
This issue has a mass of 46.
We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.
The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.
If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.
See codeclimate-duplication
's documentation for more information about tuning the mass threshold in your .codeclimate.yml
.
Refactorings
- Extract Method
- Extract Class
- Form Template Method
- Introduce Null Object
- Pull Up Method
- Pull Up Field
- Substitute Algorithm
Further Reading
- Don't Repeat Yourself on the C2 Wiki
- Duplicated Code on SourceMaking
- Refactoring: Improving the Design of Existing Code by Martin Fowler. Duplicated Code, p76
Identical blocks of code found in 3 locations. Consider refactoring. Open
animationEasing:"swing"};var S=["left","right","top","bottom"];var E=["top","bottom","center"];var x=["left","right","center"];var L={left:E,right:E,top:x,bottom:x};function nextItem(e,t){var i=t.indexOf(e);return i===t.length-1?t[0]:t[i+1]}var R=function(e){_inherits(Positionable,e);var t=_createSuper(Positionable);function Positionable(){_classCallCheck(this,Positionable);return t.apply(this,arguments)}_createClass(Positionable,[{key:"_init",value:function _init(){this.triedPositions={};this.position="auto"===this.options.position?this._getDefaultPosition():this.options.position;this.alignment="auto"===this.options.alignment?this._getDefaultAlignment():this.options.alignment;this.originalPosition=this.position;this.originalAlignment=this.alignment}},{key:"_getDefaultPosition",value:function _getDefaultPosition(){return"bottom"}},{key:"_getDefaultAlignment",value:function _getDefaultAlignment(){switch(this.position){case"bottom":case"top":return rtl()?"right":"left";case"left":case"right":return"bottom"}}},{key:"_reposition",value:function _reposition(){if(this._alignmentsExhausted(this.position)){this.position=nextItem(this.position,S);this.alignment=L[this.position][0]}else this._realign()}},{key:"_realign",value:function _realign(){this._addTriedPosition(this.position,this.alignment);this.alignment=nextItem(this.alignment,L[this.position])}},{key:"_addTriedPosition",value:function _addTriedPosition(e,t){this.triedPositions[e]=this.triedPositions[e]||[];this.triedPositions[e].push(t)}},{key:"_positionsExhausted",value:function _positionsExhausted(){var e=true;for(var t=0;t<S.length;t++)e=e&&this._alignmentsExhausted(S[t]);return e}},{key:"_alignmentsExhausted",value:function _alignmentsExhausted(e){return this.triedPositions[e]&&this.triedPositions[e].length===L[e].length}},{key:"_getVOffset",value:function _getVOffset(){return this.options.vOffset}},{key:"_getHOffset",value:function _getHOffset(){return this.options.hOffset}},{key:"_setPosition",value:function _setPosition(e,t,i){if("false"===e.attr("aria-expanded"))return false;if(!this.options.allowOverlap){this.position=this.originalPosition;this.alignment=this.originalAlignment}t.offset(a.GetExplicitOffsets(t,e,this.position,this.alignment,this._getVOffset(),this._getHOffset()));if(!this.options.allowOverlap){var n=1e8;var s={position:this.position,alignment:this.alignment};while(!this._positionsExhausted()){var o=a.OverlapArea(t,i,false,false,this.options.allowBottomOverlap);if(0===o)return;if(o<n){n=o;s={position:this.position,alignment:this.alignment}}this._reposition();t.offset(a.GetExplicitOffsets(t,e,this.position,this.alignment,this._getVOffset(),this._getHOffset()))}this.position=s.position;this.alignment=s.alignment;t.offset(a.GetExplicitOffsets(t,e,this.position,this.alignment,this._getVOffset(),this._getHOffset()))}}}]);return Positionable}(C);R.defaults={
- Read upRead up
Duplicated Code
Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:
Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.
When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).
Tuning
This issue has a mass of 46.
We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.
The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.
If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.
See codeclimate-duplication
's documentation for more information about tuning the mass threshold in your .codeclimate.yml
.
Refactorings
- Extract Method
- Extract Class
- Form Template Method
- Introduce Null Object
- Pull Up Method
- Pull Up Field
- Substitute Algorithm
Further Reading
- Don't Repeat Yourself on the C2 Wiki
- Duplicated Code on SourceMaking
- Refactoring: Improving the Design of Existing Code by Martin Fowler. Duplicated Code, p76
Similar blocks of code found in 2 locations. Consider refactoring. Open
}, nodeIsBlockStartComment: function(t3) {
return e.nodeIsCommentNode(t3) && (t3 != null ? t3.data : void 0) === "block";
}, nodeIsCommentNode: function(t3) {
- Read upRead up
Duplicated Code
Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:
Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.
When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).
Tuning
This issue has a mass of 46.
We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.
The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.
If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.
See codeclimate-duplication
's documentation for more information about tuning the mass threshold in your .codeclimate.yml
.
Refactorings
- Extract Method
- Extract Class
- Form Template Method
- Introduce Null Object
- Pull Up Method
- Pull Up Field
- Substitute Algorithm
Further Reading
- Don't Repeat Yourself on the C2 Wiki
- Duplicated Code on SourceMaking
- Refactoring: Improving the Design of Existing Code by Martin Fowler. Duplicated Code, p76
Similar blocks of code found in 2 locations. Consider refactoring. Open
}, i.textForStringWithAttributes = function(t3, n3) {
var i2;
return i2 = new e.StringPiece(t3, n3), new this([i2]);
}, i.fromJSON = function(t3) {
- Read upRead up
Duplicated Code
Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:
Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.
When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).
Tuning
This issue has a mass of 46.
We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.
The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.
If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.
See codeclimate-duplication
's documentation for more information about tuning the mass threshold in your .codeclimate.yml
.
Refactorings
- Extract Method
- Extract Class
- Form Template Method
- Introduce Null Object
- Pull Up Method
- Pull Up Field
- Substitute Algorithm
Further Reading
- Don't Repeat Yourself on the C2 Wiki
- Duplicated Code on SourceMaking
- Refactoring: Improving the Design of Existing Code by Martin Fowler. Duplicated Code, p76
Similar blocks of code found in 2 locations. Consider refactoring. Open
function _setup(t,i){this.$element=t;this.options=e.extend({},Interchange.defaults,this.$element.data(),i);this.rules=[];this.currentPath="";this.className="Interchange";k.init(e);this._init();this._events()}},{key:"_init",value:function _init(){i._init();var e=this.$element[0].id||GetYoDigits(6,"interchange");this.$element.attr({"data-resize":e,id:e});this._parseOptions();this._addBreakpoints();this._generateRules();this._reflow()}},{key:"_events",value:function _events(){var e=this;this.$element.off("resizeme.zf.trigger").on("resizeme.zf.trigger",(function(){return e._reflow()}))}},{key:"_reflow",value:function _reflow(){var e;for(var t in this.rules)if(this.rules.hasOwnProperty(t)){var i=this.rules[t];window.matchMedia(i.query).matches&&(e=i)}e&&this.replace(e.path)}},{key:"_parseOptions",value:function _parseOptions(){var e=["auto","src","background","html"];if("undefined"===typeof this.options.type)this.options.type="auto";else if(-1===e.indexOf(this.options.type)){console.warn('Warning: invalid value "'.concat(this.options.type,'" for Interchange option "type"'));this.options.type="auto"}}},{key:"_addBreakpoints",value:function _addBreakpoints(){for(var e in i.queries)if(i.queries.hasOwnProperty(e)){var t=i.queries[e];Interchange.SPECIAL_QUERIES[t.name]=t.value}}
- Read upRead up
Duplicated Code
Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:
Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.
When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).
Tuning
This issue has a mass of 45.
We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.
The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.
If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.
See codeclimate-duplication
's documentation for more information about tuning the mass threshold in your .codeclimate.yml
.
Refactorings
- Extract Method
- Extract Class
- Form Template Method
- Introduce Null Object
- Pull Up Method
- Pull Up Field
- Substitute Algorithm
Further Reading
- Don't Repeat Yourself on the C2 Wiki
- Duplicated Code on SourceMaking
- Refactoring: Improving the Design of Existing Code by Martin Fowler. Duplicated Code, p76
Similar blocks of code found in 2 locations. Consider refactoring. Open
*/},{key:"scrollToLoc",value:function scrollToLoc(e){this._inTransition=true;var t=this;var i={animationEasing:this.options.animationEasing,animationDuration:this.options.animationDuration,threshold:this.options.threshold,offset:this.options.offset};I.scrollToLoc(e,i,(function(){t._inTransition=false}))}},{key:"reflow",value:function reflow(){this.calcPoints();this._updateActive()}},{key:"_updateActive",value:function _updateActive(){var t=this;if(!this._inTransition){var i=parseInt(window.pageYOffset,10);var n=this.scrollPos>i;this.scrollPos=i;var s;if(i<this.points[0]-this.options.offset-(n?this.options.threshold:0));else if(i+this.winHeight===this.docHeight)s=this.points.length-1;else{var a=this.points.filter((function(e){return e-t.options.offset-(n?t.options.threshold:0)<=i}));s=a.length?a.length-1:0}var o=this.$active;var r="";if("undefined"!==typeof s){this.$active=this.$links.filter('[href="#'+this.$targets.eq(s).data("magellan-target")+'"]');this.$active.length&&(r=this.$active[0].getAttribute("href"))}else this.$active=e();var l=!(!this.$active.length&&!o.length)&&!this.$active.is(o);var c=r!==window.location.hash;if(l){o.removeClass(this.options.activeClass);this.$active.addClass(this.options.activeClass)}if(this.options.deepLinking&&c)if(window.history.pushState){var h=r||window.location.pathname+window.location.search;this.options.updateHistory?window.history.pushState({},"",h):window.history.replaceState({},"",h)}else window.location.hash=r;l&&this.$element.trigger("update.zf.magellan",[this.$active])}}},{key:"_destroy",value:function _destroy(){this.$element.off(".zf.trigger .zf.magellan").find(".".concat(this.options.activeClass)).removeClass(this.options.activeClass);if(this.options.deepLinking){var t=this.$active[0].getAttribute("href");window.location.hash.replace(t,"")}e(window).off("hashchange",this._deepLinkScroll);this.onLoadListener&&e(window).off(this.onLoadListener)}}]);return Magellan}(C);q.defaults={
- Read upRead up
Duplicated Code
Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:
Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.
When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).
Tuning
This issue has a mass of 45.
We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.
The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.
If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.
See codeclimate-duplication
's documentation for more information about tuning the mass threshold in your .codeclimate.yml
.
Refactorings
- Extract Method
- Extract Class
- Form Template Method
- Introduce Null Object
- Pull Up Method
- Pull Up Field
- Substitute Algorithm
Further Reading
- Don't Repeat Yourself on the C2 Wiki
- Duplicated Code on SourceMaking
- Refactoring: Improving the Design of Existing Code by Martin Fowler. Duplicated Code, p76
Similar blocks of code found in 2 locations. Consider refactoring. Open
}, historyUndo: function() {
var t3;
return (t3 = this.delegate) != null ? t3.inputControllerWillPerformUndo() : void 0;
}, insertCompositionText: function() {
- Read upRead up
Duplicated Code
Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:
Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.
When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).
Tuning
This issue has a mass of 45.
We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.
The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.
If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.
See codeclimate-duplication
's documentation for more information about tuning the mass threshold in your .codeclimate.yml
.
Refactorings
- Extract Method
- Extract Class
- Form Template Method
- Introduce Null Object
- Pull Up Method
- Pull Up Field
- Substitute Algorithm
Further Reading
- Don't Repeat Yourself on the C2 Wiki
- Duplicated Code on SourceMaking
- Refactoring: Improving the Design of Existing Code by Martin Fowler. Duplicated Code, p76
Similar blocks of code found in 2 locations. Consider refactoring. Open
_getCurrentSize:function _getCurrentSize(){var e;for(var t=0;t<this.queries.length;t++){var i=this.queries[t];window.matchMedia(i.value).matches&&(e=i)}return e&&this._getQueryName(e)},_watcher:function _watcher(){var t=this;e(window).on("resize.zf.trigger",(function(){var i=t._getCurrentSize(),n=t.current;if(i!==n){t.current=i;e(window).trigger("changed.zf.mediaquery",[i,n])}}))}};function parseStyleToObject(e){var t={};if("string"!==typeof e)return t;e=e.trim().slice(1,-1);if(!e)return t;t=e.split("&").reduce((function(e,t){var i=t.replace(/\+/g," ").split("=");var n=i[0];var s=i[1];n=decodeURIComponent(n);s="undefined"===typeof s?null:decodeURIComponent(s);e.hasOwnProperty(n)?Array.isArray(e[n])?e[n].push(s):e[n]=[e[n],s]:e[n]=s;return e}),{});return t}var n="6.7.5";var s={version:n,_plugins:{},_uuids:[],
- Read upRead up
Duplicated Code
Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:
Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.
When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).
Tuning
This issue has a mass of 45.
We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.
The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.
If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.
See codeclimate-duplication
's documentation for more information about tuning the mass threshold in your .codeclimate.yml
.
Refactorings
- Extract Method
- Extract Class
- Form Template Method
- Introduce Null Object
- Pull Up Method
- Pull Up Field
- Substitute Algorithm
Further Reading
- Don't Repeat Yourself on the C2 Wiki
- Duplicated Code on SourceMaking
- Refactoring: Improving the Design of Existing Code by Martin Fowler. Duplicated Code, p76
Similar blocks of code found in 2 locations. Consider refactoring. Open
}, historyRedo: function() {
var t3;
return (t3 = this.delegate) != null ? t3.inputControllerWillPerformRedo() : void 0;
}, historyUndo: function() {
- Read upRead up
Duplicated Code
Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:
Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.
When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).
Tuning
This issue has a mass of 45.
We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.
The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.
If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.
See codeclimate-duplication
's documentation for more information about tuning the mass threshold in your .codeclimate.yml
.
Refactorings
- Extract Method
- Extract Class
- Form Template Method
- Introduce Null Object
- Pull Up Method
- Pull Up Field
- Substitute Algorithm
Further Reading
- Don't Repeat Yourself on the C2 Wiki
- Duplicated Code on SourceMaking
- Refactoring: Improving the Design of Existing Code by Martin Fowler. Duplicated Code, p76