diff --git a/public/src/modules/pictureCropper.js b/public/src/modules/pictureCropper.js index 25bfd6794b..8f7ba364dd 100644 --- a/public/src/modules/pictureCropper.js +++ b/public/src/modules/pictureCropper.js @@ -34,7 +34,7 @@ define('pictureCropper', ['cropper'], function (Cropper) { }, function (cropperModal) { cropperModal.modal({ backdrop: 'static', - }).modal('hide'); + }).modal('show'); // Set cropper image max-height based on viewport var cropBoxHeight = parseInt($(window).height() / 2, 10); @@ -62,11 +62,9 @@ define('pictureCropper', ['cropper'], function (Cropper) { }, ready: function () { if (!checkCORS(cropperTool, data)) { - return; + return cropperModal.modal('hide'); } - cropperModal.modal('show'); - if (data.restrictImageDimension) { var origDimension = (img.width < img.height) ? img.width : img.height; var dimension = (origDimension > data.imageDimension) ? data.imageDimension : origDimension;