(function() {
    'use strict';

    angular
        .module('app', ['ngMaterial', 'ngMessages', 'ngCookies', 'ngSanitize'])
        .config(['$mdThemingProvider', '$mdIconProvider', '$httpProvider', function($mdThemingProvider, $mdIconProvider, $httpProvider) {
            $mdThemingProvider.theme('default')
                .primaryPalette('green')
                .accentPalette('grey')
                .warnPalette('red',  {'default': '700'});
            $httpProvider.defaults.transformRequest = function(data) {
                if (data === undefined) {
                    return data;
                }
                return $.param(data);
            };
            $httpProvider.defaults.headers.post['Content-Type'] =
                'application/x-www-form-urlencoded; charset=UTF-8';
            $httpProvider.defaults.headers.common['X-Requested-With'] =
                'XMLHttpRequest';
            $httpProvider.defaults.xsrfHeaderName = 'X-CSRF-Token';
            $httpProvider.defaults.xsrfCookieName = 'csrfToken';
        }])
        .filter('urlEncode', function() {
            return function(input) {
                if (input) {
                    return window.encodeURIComponent(input);
                }
                return "";
            };
        });
})();

@@ -193,25 +193,58 @@
 vider', 
-function(
+'$cookiesProvider', function(%0A            
 $mdThemi
@@ -285,16 +285,43 @@
 Provider
+, $cookiesProvider%0A        
 ) %7B%0A    
@@ -1087,24 +1087,204 @@
 'csrfToken';
+%0A%0A            var date = new Date();%0A            $cookiesProvider.defaults.path = '/';%0A            $cookiesProvider.defaults.expires = new Date(date.setMonth(date.getMonth() + 1));
 %0A        %7D%5D)

Set global path and +1 month expiration date in angular cookies