From 5dc7b96638c80c21211ca055b72e425c50ac9d75 Mon Sep 17 00:00:00 2001 From: Nate-Wilkins Date: Tue, 22 Jul 2014 15:56:41 -0400 Subject: [PATCH] fix(umd): #340 pass in root instead of deps Follow outlined UMD (Universal Module Definition) - https://github.com/umdjs/umd/blob/master/amdWeb.js Related Issues: - https://github.com/esvit/ng-table/issues/340 - https://github.com/esvit/ng-table/pull/284 - https://github.com/esvit/ng-table/pull/307 --- ng-table.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ng-table.js b/ng-table.js index a949fe03..fe4b320f 100644 --- a/ng-table.js +++ b/ng-table.js @@ -1,4 +1,4 @@ -(function(angular, factory) { +(function(root, factory) { 'use strict'; if (typeof define === 'function' && define.amd) { @@ -6,9 +6,9 @@ return factory(angular); }); } else { - return factory(angular); + return factory(root.angular); } -}(angular || null, function(angular) { +}(this, function(angular) { 'use strict'; /** * ngTable: Table + Angular JS @@ -715,4 +715,4 @@ angular.module('ngTable').run(['$templateCache', function ($templateCache) { $templateCache.put('ng-table/pager.html', '
'); }]); return app; -})); \ No newline at end of file +}));