angular-translate-loader-url
Advanced tools
Comparing version 2.7.2 to 2.8.0
/*! | ||
* angular-translate - v2.7.2 - 2015-06-01 | ||
* http://github.com/angular-translate/angular-translate | ||
* Copyright (c) 2015 ; Licensed MIT | ||
* angular-translate - v2.8.0 - 2015-09-18 | ||
* | ||
* Copyright (c) 2015 The angular-translate team, Pascal Precht; Licensed MIT | ||
*/ | ||
@@ -52,18 +52,16 @@ (function (root, factory) { | ||
var deferred = $q.defer(), | ||
requestParams = {}; | ||
var requestParams = {}; | ||
requestParams[options.queryParameter || 'lang'] = options.key; | ||
$http(angular.extend({ | ||
return $http(angular.extend({ | ||
url: options.url, | ||
params: requestParams, | ||
method: 'GET' | ||
}, options.$http)).success(function (data) { | ||
deferred.resolve(data); | ||
}).error(function () { | ||
deferred.reject(options.key); | ||
}); | ||
return deferred.promise; | ||
}, options.$http)) | ||
.then(function(result) { | ||
return result.data; | ||
}, function () { | ||
return $q.reject(options.key); | ||
}); | ||
}; | ||
@@ -70,0 +68,0 @@ } |
/*! | ||
* angular-translate - v2.7.2 - 2015-06-01 | ||
* http://github.com/angular-translate/angular-translate | ||
* Copyright (c) 2015 ; Licensed MIT | ||
* angular-translate - v2.8.0 - 2015-09-18 | ||
* | ||
* Copyright (c) 2015 The angular-translate team, Pascal Precht; Licensed MIT | ||
*/ | ||
!function(a,b){"function"==typeof define&&define.amd?define([],function(){return b()}):"object"==typeof exports?module.exports=b():b()}(this,function(){function a(a,b){"use strict";return function(c){if(!c||!c.url)throw new Error("Couldn't use urlLoader since no url is given!");var d=a.defer(),e={};return e[c.queryParameter||"lang"]=c.key,b(angular.extend({url:c.url,params:e,method:"GET"},c.$http)).success(function(a){d.resolve(a)}).error(function(){d.reject(c.key)}),d.promise}}return angular.module("pascalprecht.translate").factory("$translateUrlLoader",a),a.$inject=["$q","$http"],a.displayName="$translateUrlLoader","pascalprecht.translate"}); | ||
!function(a,b){"function"==typeof define&&define.amd?define([],function(){return b()}):"object"==typeof exports?module.exports=b():b()}(this,function(){function a(a,b){"use strict";return function(c){if(!c||!c.url)throw new Error("Couldn't use urlLoader since no url is given!");var d={};return d[c.queryParameter||"lang"]=c.key,b(angular.extend({url:c.url,params:d,method:"GET"},c.$http)).then(function(a){return a.data},function(){return a.reject(c.key)})}}return angular.module("pascalprecht.translate").factory("$translateUrlLoader",a),a.$inject=["$q","$http"],a.displayName="$translateUrlLoader","pascalprecht.translate"}); |
{ | ||
"name": "angular-translate-loader-url", | ||
"description": "A plugin for Angular Translate", | ||
"version": "2.7.2", | ||
"version": "2.8.0", | ||
"main": "./angular-translate-loader-url.js", | ||
"ignore": [], | ||
"author": "Pascal Precht", | ||
"licenses": [ | ||
{ | ||
"type": "MIT", | ||
"url": "http://www.opensource.org/licenses/MIT" | ||
} | ||
], | ||
"license": "MIT", | ||
"dependencies": { | ||
"angular-translate": "~2.7.2" | ||
"angular-translate": "~2.8.0" | ||
} | ||
} |
{ | ||
"name": "angular-translate-loader-url", | ||
"version": "2.7.2", | ||
"version": "2.8.0", | ||
"description": "Creates a loading function for a typical dynamic url pattern: \"locale.php?lang=en_US\", \"locale.php?lang=de_DE\", \"locale.php?language=nl_NL\" etc. Prefixing the specified url, the current requested, language id will be applied with \"?{queryParameter}={key}\". Using this service, the response of these urls must be an object of key-value pairs.", | ||
@@ -22,4 +22,4 @@ "main": "angular-translate-loader-url.js", | ||
"dependencies": { | ||
"angular-translate": "~2.7.2" | ||
"angular-translate": "~2.8.0" | ||
} | ||
} |
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
7966
11
0
80
+ Addedangular-translate@2.8.1(transitive)
- Removedangular-translate@2.7.2(transitive)
Updatedangular-translate@~2.8.0