Skip to content
This repository has been archived by the owner on Feb 15, 2022. It is now read-only.

Commit

Permalink
Bug #21, fix user registration bug - config reCaptcha key [iet:4858527]
Browse files Browse the repository at this point in the history
  • Loading branch information
nfreear committed Jan 12, 2016
1 parent 2f7fade commit f0ad6c5
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion app/src/main/webapp/WEB-INF/nquireit.properties.default
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,6 @@ google.consumerSecret=secret
twitter.consumerKey=key
twitter.consumerSecret=secret

# The siteKey is hard-coded into profile-controller.js - TODO use this config file
# reCaptcha site key - see: 'static/src/js/app/config.js'
recaptcha.siteKey=key
recaptcha.secretKey=secret
4 changes: 4 additions & 0 deletions static/src/js/app/config.js.DIST.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@

angular.module('senseItWeb').constant('senseItConfig', {

recaptcha: {
siteKey: "6Lf2DhUTAAAAAFHjZKAbauPlEtiegg0nFf41-msN"
},

// LEAVE me in the '.DIST.html' file - just for translation purposes!
texts_translate: [
"{{ 'The site will be undergoing routine maintenance today, {{DATE}}.' | translate }}",
Expand Down
4 changes: 2 additions & 2 deletions static/src/js/app/controllers/profile/profile-controller.js
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ angular.module('senseItWeb', null, null).controller('ProfileCtrl', function ($sc
};

$scope.register = {
recaptcha: {siteKey: "6Ld4FAYTAAAAAGPfId4I1ecr8fgTRTWTcAxBeTpA"},
recaptcha: {siteKey: $scope.cfg.recaptcha.siteKey},
editing: {username: '', password: '', repeatPassword: '', email: ''},
error: {username: false, password: false, repeatPassword: false, email: false, recaptcha: false},
clearPassword: function () {
Expand Down Expand Up @@ -224,7 +224,7 @@ angular.module('senseItWeb', null, null).controller('ProfileCtrl', function ($sc


$scope.reminder = {
recaptcha: {siteKey: "6Ld4FAYTAAAAAGPfId4I1ecr8fgTRTWTcAxBeTpA"},
recaptcha: {siteKey: $scope.cfg.recaptcha.siteKey},
editing: {email: ''},
error: {email: false},
reset: function () {
Expand Down

0 comments on commit f0ad6c5

Please sign in to comment.