Permalink
Browse files

Moved mapping into config file & switched challenge ids for keys

  • Loading branch information...
J12934 committed Apr 11, 2018
1 parent 01b2d0f commit 7ef76b3a5a53d374e89d939971d8c57eca2791fb
@@ -23,7 +23,7 @@ angular.module('juiceShop').controller('ChallengeSolvedNotificationController',
}, function (translationId) {
return translationId
}).then(function (message) {
var country = $scope.showCtfCountryDetailsInNotifications ? $scope.countryMap[challenge.id.toString()] : null
var country = $scope.showCtfCountryDetailsInNotifications ? $scope.countryMap[challenge.key] : null
$scope.notifications.push({
message: message,
flag: challenge.flag,
@@ -4,7 +4,7 @@ angular.module('juiceShop').factory('CountryMappingService', ['$http', '$q', fun
function getCountryMapping () {
var countryMapping = $q.defer()
$http.get('/public/country-mapping.json').success(function (data) {
$http.get('/rest/country-mapping').success(function (data) {
countryMapping.resolve(data)
}).error(function (err) {
countryMapping.reject(err)

This file was deleted.

Oops, something went wrong.
Oops, something went wrong.

0 comments on commit 7ef76b3

Please sign in to comment.