Skip to content

Commit 4b5b468

Browse files
committed
upgrade to AngularJS 1.0.3 bouncy-thunder
1 parent 5c742c3 commit 4b5b468

14 files changed

+735
-461
lines changed

app/lib/angular/angular-cookies.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* @license AngularJS v1.0.2
2+
* @license AngularJS v1.0.3
33
* (c) 2010-2012 Google, Inc. http://angularjs.org
44
* License: MIT
55
*/

app/lib/angular/angular-cookies.min.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
AngularJS v1.0.2
2+
AngularJS v1.0.3
33
(c) 2010-2012 Google, Inc. http://angularjs.org
44
License: MIT
55
*/

app/lib/angular/angular-loader.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* @license AngularJS v1.0.2
2+
* @license AngularJS v1.0.3
33
* (c) 2010-2012 Google, Inc. http://angularjs.org
44
* License: MIT
55
*/
@@ -36,7 +36,7 @@ function setupModuleLoader(window) {
3636
*
3737
* # Module
3838
*
39-
* A module is a collocation of services, directives, filters, and configure information. Module
39+
* A module is a collocation of services, directives, filters, and configuration information. Module
4040
* is used to configure the {@link AUTO.$injector $injector}.
4141
*
4242
* <pre>
@@ -67,7 +67,7 @@ function setupModuleLoader(window) {
6767
* @param {!string} name The name of the module to create or retrieve.
6868
* @param {Array.<string>=} requires If specified then new module is being created. If unspecified then the
6969
* the module is being retrieved for further configuration.
70-
* @param {Function} configFn Option configuration function for the module. Same as
70+
* @param {Function} configFn Optional configuration function for the module. Same as
7171
* {@link angular.Module#config Module#config()}.
7272
* @returns {module} new module with the {@link angular.Module} api.
7373
*/
@@ -222,8 +222,8 @@ function setupModuleLoader(window) {
222222
* @param {Function} initializationFn Execute this function after injector creation.
223223
* Useful for application initialization.
224224
* @description
225-
* Use this method to register work which needs to be performed when the injector with
226-
* with the current module is finished loading.
225+
* Use this method to register work which should be performed when the injector is done
226+
* loading all modules.
227227
*/
228228
run: function(block) {
229229
runBlocks.push(block);

app/lib/angular/angular-loader.min.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
AngularJS v1.0.2
2+
AngularJS v1.0.3
33
(c) 2010-2012 Google, Inc. http://angularjs.org
44
License: MIT
55
*/

app/lib/angular/angular-resource.js

Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* @license AngularJS v1.0.2
2+
* @license AngularJS v1.0.3
33
* (c) 2010-2012 Google, Inc. http://angularjs.org
44
* License: MIT
55
*/
@@ -231,7 +231,7 @@ angular.module('ngResource', ['ng']).
231231
};
232232

233233
/**
234-
* We need our custom mehtod because encodeURIComponent is too agressive and doesn't follow
234+
* We need our custom mehtod because encodeURIComponent is too aggressive and doesn't follow
235235
* http://www.ietf.org/rfc/rfc3986.txt with regards to the character set (pchar) allowed in path
236236
* segments:
237237
* segment = *pchar
@@ -285,12 +285,18 @@ angular.module('ngResource', ['ng']).
285285
url: function(params) {
286286
var self = this,
287287
url = this.template,
288+
val,
288289
encodedVal;
289290

290291
params = params || {};
291292
forEach(this.urlParams, function(_, urlParam){
292-
encodedVal = encodeUriSegment(params[urlParam] || self.defaults[urlParam] || "");
293-
url = url.replace(new RegExp(":" + urlParam + "(\\W)"), encodedVal + "$1");
293+
val = params.hasOwnProperty(urlParam) ? params[urlParam] : self.defaults[urlParam];
294+
if (angular.isDefined(val) && val !== null) {
295+
encodedVal = encodeUriSegment(val);
296+
url = url.replace(new RegExp(":" + urlParam + "(\\W)", "g"), encodedVal + "$1");
297+
} else {
298+
url = url.replace(new RegExp("/?:" + urlParam + "(\\W)", "g"), '$1');
299+
}
294300
});
295301
url = url.replace(/\/?#$/, '');
296302
var query = [];
@@ -311,9 +317,10 @@ angular.module('ngResource', ['ng']).
311317

312318
actions = extend({}, DEFAULT_ACTIONS, actions);
313319

314-
function extractParams(data){
320+
function extractParams(data, actionParams){
315321
var ids = {};
316-
forEach(paramDefaults || {}, function(value, key){
322+
actionParams = extend({}, paramDefaults, actionParams);
323+
forEach(actionParams, function(value, key){
317324
ids[key] = value.charAt && value.charAt(0) == '@' ? getter(data, value.substr(1)) : value;
318325
});
319326
return ids;
@@ -367,7 +374,7 @@ angular.module('ngResource', ['ng']).
367374
var value = this instanceof Resource ? this : (action.isArray ? [] : new Resource(data));
368375
$http({
369376
method: action.method,
370-
url: route.url(extend({}, extractParams(data), action.params || {}, params)),
377+
url: route.url(extend({}, extractParams(data, action.params || {}), params)),
371378
data: data
372379
}).then(function(response) {
373380
var data = response.data;

app/lib/angular/angular-resource.min.js

Lines changed: 6 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

app/lib/angular/angular-sanitize.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* @license AngularJS v1.0.2
2+
* @license AngularJS v1.0.3
33
* (c) 2010-2012 Google, Inc. http://angularjs.org
44
* License: MIT
55
*/
@@ -416,7 +416,7 @@ angular.module('ngSanitize', []).value('$sanitize', $sanitize);
416416
angular.module('ngSanitize').directive('ngBindHtml', ['$sanitize', function($sanitize) {
417417
return function(scope, element, attr) {
418418
element.addClass('ng-binding').data('$binding', attr.ngBindHtml);
419-
scope.$watch(attr.ngBindHtml, function(value) {
419+
scope.$watch(attr.ngBindHtml, function ngBindHtmlWatchAction(value) {
420420
value = $sanitize(value);
421421
element.html(value || '');
422422
});

app/lib/angular/angular-sanitize.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)