betajs/betajs-media-components

View on GitHub
src/dynamics/video_recorder/recorder/recorder.js

Summary

Maintainability
F
1 wk
Test Coverage

File recorder.js has 1407 lines of code (exceeds 250 allowed). Consider refactoring.
Open

Scoped.define("module:VideoRecorder.Dynamics.Recorder", [
    "dynamics:Dynamic",
    "module:Assets",
    "module:StylesMixin",
    "browser:Info",
Severity: Major
Found in src/dynamics/video_recorder/recorder/recorder.js - About 3 days to fix

    Function __buildOutsourceElement has 106 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

                    __buildOutsourceElement: function(element, options, isCamera, choosenDevice) {
                        var self = this;
                        var deviceCollections = isCamera ? this.get("cameras") : this.get("microphones");
                        var listeners = [];
                        var initialSelectorText = '';
    Severity: Major
    Found in src/dynamics/video_recorder/recorder/recorder.js - About 4 hrs to fix

      Function create has 99 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

                      create: function() {
                          this._validateParameters();
                          // Init Audio Context
                          WebRTCSupport.globals();
                          this.set("optionsinitialstate", {
      Severity: Major
      Found in src/dynamics/video_recorder/recorder/recorder.js - About 3 hrs to fix

        Function _timerFire has 86 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

                        _timerFire: function() {
                            if (this.destroyed())
                                return;
                            this.set("currentorientation", window.innerHeight > window.innerWidth ? "portrait" : "landscape");
                            try {
        Severity: Major
        Found in src/dynamics/video_recorder/recorder/recorder.js - About 3 hrs to fix

          Function _add_new_stream has 47 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

                          _add_new_stream: function(deviceId) {
                              var _selected;
                              var _currentTracks = this.recorder._recorder.stream().getTracks();
                              this.get("cameras").iterate(function(videoDevice) {
                                  var _videoDevice = videoDevice.data();
          Severity: Minor
          Found in src/dynamics/video_recorder/recorder/recorder.js - About 1 hr to fix

            Function _bindMedia has 47 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                            _bindMedia: function() {
                                if (this._bound || !this.recorderAttached() || !this.recorder)
                                    return;
                                this.recorder.ready.success(function() {
                                    if (!this.recorder) return;
            Severity: Minor
            Found in src/dynamics/video_recorder/recorder/recorder.js - About 1 hr to fix

              Function selectors has 36 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                                      var selectors = Objs.map(this.get("outsource-selectors").split(/;/), function(item) {
                                          var obj = {
                                              options: {
                                                  type: 'select',
                                                  disabled: true,
              Severity: Minor
              Found in src/dynamics/video_recorder/recorder/recorder.js - About 1 hr to fix

                Function _videoRecorderWrapperOptions has 34 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                                _videoRecorderWrapperOptions: function() {
                                    var _screen = null;
                                    var _resizeMode = this.get("resizemode");
                                    if ((this.get("allowscreen") && this.get("record_media") === "screen") || (this.get("allowmultistreams") && this.get("record_media") === "multistream")) {
                                        _screen = this.get("screen");
                Severity: Minor
                Found in src/dynamics/video_recorder/recorder/recorder.js - About 1 hr to fix

                  Function _showBackgroundSnapshot has 27 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                                  _showBackgroundSnapshot: function() {
                                      if (this.get("onlyaudio"))
                                          return;
                                      this._hideBackgroundSnapshot();
                                      if (this.get("snapshots") && this.get("selectfirstcovershotonskip")) {
                  Severity: Minor
                  Found in src/dynamics/video_recorder/recorder/recorder.js - About 1 hr to fix

                    Avoid deeply nested control flow statements.
                    Open

                                                        if (snap) {
                                                            if (!this.get('videometadata').height && typeof Image !== 'undefined' && this.get("createthumbnails")) {
                                                                RecorderSupport.snapshotMetaData(snap).success(function(data) {
                                                                    var _thumbWidth = data.orientation === 'landscape' ? 80 : 35;
                                                                    this.set("videometadata", Objs.tree_merge(this.get("videometadata"), data));
                    Severity: Major
                    Found in src/dynamics/video_recorder/recorder/recorder.js - About 45 mins to fix

                      Function containerSizingStyles:aspectratio,nativeRecordingWidth,nativeRecordingHeight,activated, height, width has 6 arguments (exceeds 4 allowed). Consider refactoring.
                      Open

                                          "containerSizingStyles:aspectratio,nativeRecordingWidth,nativeRecordingHeight,activated, height, width": function(aspectRatio, fallbackWidth, fallbackHeight, active, height, width) {
                      Severity: Minor
                      Found in src/dynamics/video_recorder/recorder/recorder.js - About 45 mins to fix

                        Consider simplifying this complex logical expression.
                        Open

                                                if (active && (Info.isInternetExplorer() || (Info.isSafari() && Info.safariVersion() < 15))) {
                                                    new ResizeObserver(function(entries) {
                                                        this.set("height", Math.floor(entries[0].target.offsetWidth / (aspectRatio || (fallbackWidth / fallbackHeight))));
                                                    }.bind(this)).observe(this.activeElement().parentElement);
                                                    result.height = Math.floor(this.activeElement().parentElement.offsetWidth / (aspectRatio || (fallbackWidth / fallbackHeight))) + "px";
                        Severity: Major
                        Found in src/dynamics/video_recorder/recorder/recorder.js - About 40 mins to fix

                          Identical blocks of code found in 2 locations. Consider refactoring.
                          Open

                                              try {
                                                  if (this.recorderAttached() && this._timer.fire_count() % 20 === 0 && this._accessing_camera) {
                                                      var signal = this.blankLevel() >= 0.01;
                                                      if (signal !== this.__cameraSignal) {
                                                          this.__cameraSignal = signal;
                          Severity: Major
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 1 other location - About 1 day to fix
                          src/dynamics/image_capture/capture/capture.js on lines 505..521

                          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 245.

                          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

                          Further Reading

                          Similar blocks of code found in 2 locations. Consider refactoring.
                          Open

                                          _uploadVideoFile: function(file) {
                                              if (this.get("simulate"))
                                                  return;
                                              var uploader = FileUploader.create(Objs.extend({
                                                  source: file
                          Severity: Major
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 1 other location - About 3 hrs to fix
                          src/dynamics/audio_recorder/recorder/recorder.js on lines 421..430

                          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 102.

                          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

                          Further Reading

                          Similar blocks of code found in 4 locations. Consider refactoring.
                          Open

                                              if (!fitStrategies.includes(this.get("posterfitstrategy"))) {
                                                  console.warn("Invalid value for posterfitstrategy: " + this.get("posterfitstrategy") + "\nPossible values are: " + fitStrategies.slice(0, -1).join(", ") + " or " + fitStrategies.slice(-1));
                                              }
                          Severity: Major
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 3 other locations - About 2 hrs to fix
                          src/dynamics/video_player/player/player.js on lines 1461..1463
                          src/dynamics/video_player/player/player.js on lines 1464..1466
                          src/dynamics/video_recorder/recorder/recorder.js on lines 534..536

                          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 93.

                          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

                          Further Reading

                          Similar blocks of code found in 4 locations. Consider refactoring.
                          Open

                                              if (!fitStrategies.includes(this.get("videofitstrategy"))) {
                                                  console.warn("Invalid value for videofitstrategy: " + this.get("videofitstrategy") + "\nPossible values are: " + fitStrategies.slice(0, -1).join(", ") + " or " + fitStrategies.slice(-1));
                                              }
                          Severity: Major
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 3 other locations - About 2 hrs to fix
                          src/dynamics/video_player/player/player.js on lines 1461..1463
                          src/dynamics/video_player/player/player.js on lines 1464..1466
                          src/dynamics/video_recorder/recorder/recorder.js on lines 537..539

                          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 93.

                          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

                          Further Reading

                          Similar blocks of code found in 6 locations. Consider refactoring.
                          Open

                                              if (this.get("theme") in Assets.recorderthemes) {
                                                  Objs.iter(Assets.recorderthemes[this.get("theme")], function(value, key) {
                                                      if (!this.isArgumentAttr(key))
                                                          this.set(key, value);
                                                  }, this);
                          Severity: Major
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 5 other locations - About 2 hrs to fix
                          src/dynamics/audio_player/player/player.js on lines 180..185
                          src/dynamics/audio_recorder/recorder/recorder.js on lines 200..205
                          src/dynamics/image_capture/capture/capture.js on lines 199..204
                          src/dynamics/image_viewer/viewer/image_viewer.js on lines 117..122
                          src/dynamics/video_player/player/player.js on lines 1033..1038

                          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 85.

                          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

                          Further Reading

                          Similar blocks of code found in 2 locations. Consider refactoring.
                          Open

                                          videoWidth: function() {
                                              var _clientWidth = (window.innerWidth || document.body.clientWidth);
                                              if (!this.recorderAttached())
                                                  return _clientWidth;
                                              else {
                          Severity: Major
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 1 other location - About 2 hrs to fix
                          src/dynamics/video_recorder/recorder/recorder.js on lines 1270..1278

                          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 84.

                          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

                          Further Reading

                          Similar blocks of code found in 2 locations. Consider refactoring.
                          Open

                                          videoHeight: function() {
                                              var _clientHeight = (window.innerHeight || document.body.clientHeight);
                                              if (!this.recorderAttached())
                                                  return _clientHeight;
                                              else {
                          Severity: Major
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 1 other location - About 2 hrs to fix
                          src/dynamics/video_recorder/recorder/recorder.js on lines 1280..1288

                          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 84.

                          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

                          Further Reading

                          Identical blocks of code found in 3 locations. Consider refactoring.
                          Open

                                                  this.recorder.bindMedia().error(function(e) {
                                                      this.trigger("access_forbidden", e);
                                                      this.set("hideoverlay", false);
                                                      this.off("require_display", null, this);
                                                      this._error("bind", e);
                          Severity: Major
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 2 other locations - About 2 hrs to fix
                          src/dynamics/audio_recorder/recorder/recorder.js on lines 339..392
                          src/dynamics/image_capture/capture/capture.js on lines 336..354

                          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 81.

                          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

                          Further Reading

                          Similar blocks of code found in 2 locations. Consider refactoring.
                          Open

                                              "nativeRecordingWidth:recordingwidth,record_media": function() {
                                                  return this.get("recordingwidth") || ((this.get("record_media") !== "screen" && (this.get("record_media") !== "multistream")) ? 640 : (window.innerWidth || document.body.clientWidth));
                                              },
                          Severity: Major
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 1 other location - About 2 hrs to fix
                          src/dynamics/video_recorder/recorder/recorder.js on lines 227..229

                          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 75.

                          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

                          Further Reading

                          Similar blocks of code found in 2 locations. Consider refactoring.
                          Open

                                              "nativeRecordingHeight:recordingheight,record_media": function() {
                                                  return this.get("recordingheight") || ((this.get("record_media") !== "screen" && (this.get("record_media") !== "multistream")) ? 480 : (window.innerHeight || document.body.clientHeight));
                                              },
                          Severity: Major
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 1 other location - About 2 hrs to fix
                          src/dynamics/video_recorder/recorder/recorder.js on lines 224..226

                          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 75.

                          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

                          Further Reading

                          Similar blocks of code found in 2 locations. Consider refactoring.
                          Open

                                              return this.recorder.startRecord({
                                                  video: this.get("uploadoptions").video,
                                                  audio: this.get("uploadoptions").audio,
                                                  webrtcStreaming: this.get("uploadoptions").webrtcStreaming
                                              }).success(function() {
                          Severity: Major
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 1 other location - About 1 hr to fix
                          src/dynamics/audio_recorder/recorder/recorder.js on lines 453..461

                          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 70.

                          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

                          Further Reading

                          Similar blocks of code found in 2 locations. Consider refactoring.
                          Open

                                          _initializeUploader: function() {
                                              if (this._videoUploader) this._videoUploader.weakDestroy();
                                              if (this._dataUploader) this._dataUploader.weakDestroy();
                                              this._dataUploader = new MultiUploader();
                                          },
                          Severity: Major
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 1 other location - About 1 hr to fix
                          src/dynamics/audio_recorder/recorder/recorder.js on lines 408..412

                          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 68.

                          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

                          Further Reading

                          Similar blocks of code found in 3 locations. Consider refactoring.
                          Open

                                              "change:webrtconmobile": function() {
                                                  this.set("recordviafilecapture", Info.isMobile() && (!this.get("webrtconmobile") || !VideoRecorderWrapper.anySupport(this._videoRecorderWrapperOptions())));
                                              },
                          Severity: Major
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 2 other locations - About 1 hr to fix
                          src/dynamics/audio_recorder/recorder/recorder.js on lines 181..183
                          src/dynamics/image_capture/capture/capture.js on lines 184..186

                          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 64.

                          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

                          Further Reading

                          Identical blocks of code found in 5 locations. Consider refactoring.
                          Open

                                          _error: function(error_type, error_code) {
                                              this.__error = {
                                                  error_type: error_type,
                                                  error_code: error_code
                                              };
                          Severity: Major
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 4 other locations - About 1 hr to fix
                          src/dynamics/audio_player/player/player.js on lines 251..258
                          src/dynamics/audio_recorder/recorder/recorder.js on lines 264..271
                          src/dynamics/image_capture/capture/capture.js on lines 274..281
                          src/dynamics/video_player/player/player.js on lines 1370..1377

                          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 63.

                          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

                          Further Reading

                          Similar blocks of code found in 4 locations. Consider refactoring.
                          Open

                                          destroy: function() {
                                              this._timer.destroy();
                                              this.host.destroy();
                                              this._detachRecorder();
                                              inherited.destroy.call(this);
                          Severity: Major
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 3 other locations - About 1 hr to fix
                          src/dynamics/audio_player/player/player.js on lines 618..623
                          src/dynamics/audio_recorder/recorder/recorder.js on lines 608..613
                          src/dynamics/image_capture/capture/capture.js on lines 475..480

                          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 63.

                          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

                          Further Reading

                          Identical blocks of code found in 2 locations. Consider refactoring.
                          Open

                                              if (this.get("recordviafilecapture")) {
                                                  this.set("skipinitial", false);
                                                  this.set("skipinitialonrerecord", false);
                                                  this.set("autorecord", false);
                                                  this._screenRecorderVerifier(false);
                          Severity: Major
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 1 other location - About 1 hr to fix
                          src/dynamics/video_recorder/recorder/recorder.js on lines 350..355

                          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 62.

                          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

                          Further Reading

                          Identical blocks of code found in 2 locations. Consider refactoring.
                          Open

                                                  if (this.get("recordviafilecapture")) {
                                                      this.set("skipinitial", false);
                                                      this.set("skipinitialonrerecord", false);
                                                      this.set("autorecord", false);
                                                      this._screenRecorderVerifier(false);
                          Severity: Major
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 1 other location - About 1 hr to fix
                          src/dynamics/video_recorder/recorder/recorder.js on lines 438..443

                          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 62.

                          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

                          Further Reading

                          Similar blocks of code found in 3 locations. Consider refactoring.
                          Open

                                              pause: function() {
                                                  if (this._delegatedRecorder) {
                                                      this._delegatedRecorder.execute("pause");
                                                      return;
                                                  }
                          Severity: Major
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 2 other locations - About 1 hr to fix
                          src/dynamics/video_recorder/recorder/recorder.js on lines 934..940
                          src/dynamics/video_recorder/recorder/recorder.js on lines 1059..1065

                          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 58.

                          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

                          Further Reading

                          Similar blocks of code found in 3 locations. Consider refactoring.
                          Open

                                              play: function() {
                                                  if (this._delegatedRecorder) {
                                                      this._delegatedRecorder.execute("play");
                                                      return;
                                                  }
                          Severity: Major
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 2 other locations - About 1 hr to fix
                          src/dynamics/video_recorder/recorder/recorder.js on lines 934..940
                          src/dynamics/video_recorder/recorder/recorder.js on lines 1067..1073

                          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 58.

                          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

                          Further Reading

                          Identical blocks of code found in 3 locations. Consider refactoring.
                          Open

                                          _softwareDependencies: function() {
                                              if (!this.recorderAttached() || !this.recorder)
                                                  return Promise.error("No recorder attached.");
                                              return this.recorder.softwareDependencies();
                                          },
                          Severity: Major
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 2 other locations - About 1 hr to fix
                          src/dynamics/audio_recorder/recorder/recorder.js on lines 326..330
                          src/dynamics/image_capture/capture/capture.js on lines 323..327

                          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 58.

                          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

                          Further Reading

                          Similar blocks of code found in 3 locations. Consider refactoring.
                          Open

                                              record: function() {
                                                  if (this._delegatedRecorder) {
                                                      this._delegatedRecorder.execute("record");
                                                      return;
                                                  }
                          Severity: Major
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 2 other locations - About 1 hr to fix
                          src/dynamics/video_recorder/recorder/recorder.js on lines 1059..1065
                          src/dynamics/video_recorder/recorder/recorder.js on lines 1067..1073

                          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 58.

                          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

                          Further Reading

                          Similar blocks of code found in 2 locations. Consider refactoring.
                          Open

                                                  if (height) result.height = typeof height === "string" && height[height.length - 1] === "%" ? height : height + "px";
                          Severity: Minor
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 1 other location - About 50 mins to fix
                          src/dynamics/video_recorder/recorder/recorder.js on lines 235..235

                          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 51.

                          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

                          Further Reading

                          Similar blocks of code found in 2 locations. Consider refactoring.
                          Open

                                                  if (width) result.width = typeof width === "string" && width[width.length - 1] === "%" ? width : width + "px";
                          Severity: Minor
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 1 other location - About 50 mins to fix
                          src/dynamics/video_recorder/recorder/recorder.js on lines 234..234

                          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 51.

                          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

                          Further Reading

                          Identical blocks of code found in 2 locations. Consider refactoring.
                          Open

                                              if (this.recorder) {
                                                  this.trigger("attached");
                                                  this.set("pausable", this.get("pausable") && this.recorder.canPause());
                                              } else
                                                  this._error("attach");
                          Severity: Minor
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 1 other location - About 45 mins to fix
                          src/dynamics/audio_recorder/recorder/recorder.js on lines 318..323

                          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 50.

                          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

                          Further Reading

                          Identical blocks of code found in 2 locations. Consider refactoring.
                          Open

                                                  if (confirm(this.stringUnicode("rerecord-confirm"))) {
                                                      this.host.state().rerecord();
                                                      this._initSettings();
                                                  }
                          Severity: Minor
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 1 other location - About 45 mins to fix
                          src/dynamics/audio_recorder/recorder/recorder.js on lines 520..523

                          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 50.

                          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

                          Further Reading

                          Identical blocks of code found in 2 locations. Consider refactoring.
                          Open

                                              if (this.get("stretch") || this.get("stretchwidth") || this.get("stretchheight")) {
                                                  console.warn("Stretch parameters were deprecated, your player will stretch to the full container width by default.");
                                              }
                          Severity: Minor
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 1 other location - About 45 mins to fix
                          src/dynamics/video_player/player/player.js on lines 1467..1469

                          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 50.

                          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

                          Further Reading

                          Similar blocks of code found in 2 locations. Consider refactoring.
                          Open

                                                              if (_radio.checked && value) {
                                                                  if (isCamera) {
                                                                      self.select_camera(value);
                                                                  } else {
                                                                      self.select_microphone(value);
                          Severity: Minor
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 1 other location - About 40 mins to fix
                          src/dynamics/video_recorder/recorder/recorder.js on lines 1547..1553

                          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 48.

                          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

                          Further Reading

                          Similar blocks of code found in 2 locations. Consider refactoring.
                          Open

                                                              if (option.selected && value) {
                                                                  if (isCamera) {
                                                                      self.select_camera(value);
                                                                  } else {
                                                                      self.select_microphone(value);
                          Severity: Minor
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 1 other location - About 40 mins to fix
                          src/dynamics/video_recorder/recorder/recorder.js on lines 1522..1528

                          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 48.

                          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

                          Further Reading

                          Identical blocks of code found in 3 locations. Consider refactoring.
                          Open

                                          _unbindMedia: function() {
                                              if (!this._bound)
                                                  return;
                                              this.recorder.unbindMedia();
                                              this._bound = false;
                          Severity: Minor
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 2 other locations - About 35 mins to fix
                          src/dynamics/audio_recorder/recorder/recorder.js on lines 414..419
                          src/dynamics/image_capture/capture/capture.js on lines 364..369

                          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

                          Further Reading

                          Identical blocks of code found in 3 locations. Consider refactoring.
                          Open

                                          cloneAttrs: function() {
                                              return Objs.map(this.attrs, function(value, key) {
                                                  return this.get(key);
                                              }, this);
                                          },
                          Severity: Minor
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 2 other locations - About 30 mins to fix
                          src/dynamics/audio_player/player/player.js on lines 658..662
                          src/dynamics/image_viewer/viewer/image_viewer.js on lines 516..520

                          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

                          Further Reading

                          Similar blocks of code found in 7 locations. Consider refactoring.
                          Open

                                              manual_submit: function() {
                                                  this.set("rerecordable", false);
                                                  this.set("manualsubmit", false);
                                                  this.trigger("manually_submitted");
                                              },
                          Severity: Major
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 6 other locations - About 30 mins to fix
                          src/dynamics/audio_player/controlbar/controlbar.js on lines 174..178
                          src/dynamics/audio_recorder/recorder/recorder.js on lines 587..591
                          src/dynamics/image_capture/capture/capture.js on lines 463..467
                          src/dynamics/image_viewer/controlbar/controlbar.js on lines 37..41
                          src/dynamics/video_player/controlbar/controlbar.js on lines 286..290
                          src/dynamics/video_player/playbutton/playbutton.js on lines 35..39

                          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

                          Further Reading

                          Identical blocks of code found in 2 locations. Consider refactoring.
                          Open

                                              return this.recorder.stopRecord({
                                                  video: this.get("uploadoptions").video,
                                                  audio: this.get("uploadoptions").audio,
                                                  webrtcStreaming: this.get("uploadoptions").webrtcStreaming,
                                                  noUploading: this.get("uploadoptions").noUploading
                          Severity: Minor
                          Found in src/dynamics/video_recorder/recorder/recorder.js and 1 other location - About 30 mins to fix
                          src/dynamics/audio_recorder/recorder/recorder.js on lines 453..461

                          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

                          Further Reading

                          There are no issues that match your filters.

                          Category
                          Status