Skip to content
This repository has been archived by the owner on Mar 2, 2020. It is now read-only.

Commit

Permalink
Fix for reCaptcha fallback mode
Browse files Browse the repository at this point in the history
Workaround for the folling issues:
VividCortex#46
VividCortex#137
  • Loading branch information
Jochen Rauschenbusch committed May 26, 2016
1 parent 387e424 commit 86e4d8a
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/directive.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,12 @@

scope.$on('$destroy', destroy);

elm.find('textArea').on('paste', function(evt) {
$timeout(function() {
callback(evt.target.value);
});
});

scope.$on('reCaptchaReset', function(event, resetWidgetId){
if(ng.isUndefined(resetWidgetId) || widgetId === resetWidgetId){
scope.response = "";
Expand All @@ -77,6 +83,7 @@
if (ctrl) {
// reset the validity of the form if we were removed
ctrl.$setValidity('recaptcha', null);
elm.find('textArea').off('paste');
}

cleanup();
Expand Down

0 comments on commit 86e4d8a

Please sign in to comment.