Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug 1428051 - Remove unused Angular DI parameters #3101

Merged
merged 1 commit into from
Jan 7, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions ui/js/components/perf/compare.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
'use strict';

treeherder.component('phCompareTable', {
templateUrl: ['$element', '$attrs', function ($element, $attrs) {
templateUrl: ['$attrs', function ($attrs) {
if ($attrs.type === 'trend') {
return 'partials/perf/trendtable.html';
}
Expand All @@ -18,7 +18,7 @@ treeherder.component('phCompareTable', {
filterByFramework: '@',
releaseBlockerCriteria: '@'
},
controller: ['$element', '$attrs', function ($element, $attrs) {
controller: ['$attrs', function ($attrs) {
var ctrl = this;

if (!ctrl.baseTitle) {
Expand Down
4 changes: 2 additions & 2 deletions ui/js/controllers/bugfiler.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
"use strict";

treeherder.controller('BugFilerCtrl', [
'$scope', '$rootScope', '$uibModalInstance', '$http', 'summary',
'$scope', '$uibModalInstance', '$http', 'summary',
'search_terms', 'fullLog', 'parsedLog', 'reftest', 'selectedJob',
'allFailures', 'crashSignatures', 'successCallback', 'thNotify',
function BugFilerCtrl(
$scope, $rootScope, $uibModalInstance, $http, summary, search_terms,
$scope, $uibModalInstance, $http, summary, search_terms,
fullLog, parsedLog, reftest, selectedJob, allFailures,
crashSignatures, successCallback, thNotify) {

Expand Down
4 changes: 2 additions & 2 deletions ui/js/controllers/filters.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
"use strict";

treeherderApp.controller('JobFilterCtrl', [
'$scope', '$rootScope', '$route', '$routeParams', '$location', 'ThLog',
'$scope', '$rootScope',
'thResultStatusList', 'thEvents', 'thJobFilters',
'ThResultSetStore', 'thPinboard', 'thNotify', 'thFailureResults', 'thPinboardCountError',
function JobFilterCtrl(
$scope, $rootScope, $route, $routeParams, $location, ThLog,
$scope, $rootScope,
thResultStatusList, thEvents, thJobFilters,
ThResultSetStore, thPinboard, thNotify, thFailureResults, thPinboardCountError) {

Expand Down
30 changes: 15 additions & 15 deletions ui/js/controllers/jobs.js
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
"use strict";

treeherderApp.controller('JobsCtrl', [
'$scope', '$http', '$rootScope', '$routeParams', 'ThLog',
'thUrl', 'ThRepositoryModel', 'thDefaultRepo',
'ThResultSetStore', 'thResultStatusList', '$location', 'thEvents',
'ThJobModel', 'thNotify',
'$scope', '$rootScope', '$routeParams',
'thDefaultRepo',
'ThResultSetStore', '$location', 'thEvents',
'thNotify',
function JobsCtrl(
$scope, $http, $rootScope, $routeParams, ThLog,
thUrl, ThRepositoryModel, thDefaultRepo,
ThResultSetStore, thResultStatusList, $location, thEvents, ThJobModel, thNotify) {
$scope, $rootScope, $routeParams,
thDefaultRepo,
ThResultSetStore, $location, thEvents, thNotify) {

// load our initial set of resultsets
// scope needs this function so it can be called directly by the user, too.
Expand Down Expand Up @@ -86,17 +86,17 @@ treeherderApp.controller('JobsCtrl', [


treeherderApp.controller('ResultSetCtrl', [
'$scope', '$rootScope', '$http', 'ThLog', '$location',
'thUrl', 'thResultStatusInfo', 'thDateFormat',
'ThResultSetStore', 'thEvents', 'thJobFilters', 'thNotify',
'$scope', '$rootScope',
'thResultStatusInfo', 'thDateFormat',
'ThResultSetStore', 'thEvents', 'thNotify',
'thBuildApi', 'thPinboard', 'ThResultSetModel', 'dateFilter',
'ThModelErrors', 'ThJobModel', 'ThTaskclusterErrors', '$uibModal', 'thPinboardCountError',
'ThModelErrors', 'ThTaskclusterErrors', '$uibModal', 'thPinboardCountError',
function ResultSetCtrl(
$scope, $rootScope, $http, ThLog, $location,
thUrl, thResultStatusInfo, thDateFormat,
ThResultSetStore, thEvents, thJobFilters, thNotify,
$scope, $rootScope,
thResultStatusInfo, thDateFormat,
ThResultSetStore, thEvents, thNotify,
thBuildApi, thPinboard, ThResultSetModel, dateFilter, ThModelErrors,
ThJobModel, ThTaskclusterErrors, $uibModal, thPinboardCountError) {
ThTaskclusterErrors, $uibModal, thPinboardCountError) {

$scope.getCountClass = function (resultStatus) {
return thResultStatusInfo(resultStatus).btnClass;
Expand Down
4 changes: 2 additions & 2 deletions ui/js/controllers/logviewer.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@

logViewerApp.controller('LogviewerCtrl', [
'$location', '$window', '$document', '$rootScope', '$scope',
'$timeout', '$resource', 'ThTextLogStepModel', 'ThJobDetailModel',
'$timeout', 'ThTextLogStepModel', 'ThJobDetailModel',
'ThJobModel', 'thNotify', 'dateFilter', 'ThResultSetModel',
'thDateFormat', 'thReftestStatus', 'thUrl',
function Logviewer(
$location, $window, $document, $rootScope, $scope,
$timeout, $resource, ThTextLogStepModel, ThJobDetailModel,
$timeout, ThTextLogStepModel, ThJobDetailModel,
ThJobModel, thNotify, dateFilter, ThResultSetModel,
thDateFormat, thReftestStatus, thUrl) {

Expand Down
8 changes: 4 additions & 4 deletions ui/js/controllers/main.js
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
"use strict";

treeherderApp.controller('MainCtrl', [
'$scope', '$rootScope', '$routeParams', '$location', '$timeout', '$q',
'$scope', '$rootScope', '$location', '$timeout', '$q',
'ThLog', 'ThRepositoryModel', 'thPinboard', 'thTabs', '$document',
'thClassificationTypes', 'thEvents', '$interval', '$window', 'thNotify',
'thClassificationTypes', 'thEvents', '$interval', '$window',
'thJobFilters', 'ThResultSetStore',
'thDefaultRepo', 'thJobNavSelectors', 'thTitleSuffixLimit', '$http',
'$httpParamSerializer',
function MainController(
$scope, $rootScope, $routeParams, $location, $timeout, $q,
$scope, $rootScope, $location, $timeout, $q,
ThLog, ThRepositoryModel, thPinboard, thTabs, $document,
thClassificationTypes, thEvents, $interval, $window, thNotify,
thClassificationTypes, thEvents, $interval, $window,
thJobFilters, ThResultSetStore,
thDefaultRepo, thJobNavSelectors, thTitleSuffixLimit, $http,
$httpParamSerializer) {
Expand Down
26 changes: 13 additions & 13 deletions ui/js/controllers/perf/alerts.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
"use strict";

perf.factory('PhBugs', [
'$http', '$httpParamSerializer', '$templateRequest', '$interpolate', '$rootScope', 'dateFilter', 'thServiceDomain',
function ($http, $httpParamSerializer, $templateRequest, $interpolate, $rootScope, dateFilter, thServiceDomain) {
'$http', '$httpParamSerializer', '$interpolate', '$rootScope', 'dateFilter', 'thServiceDomain',
function ($http, $httpParamSerializer, $interpolate, $rootScope, dateFilter, thServiceDomain) {
return {
fileBug: function (alertSummary) {
$http.get(thServiceDomain + '/api/performance/bug-template/?framework=' + alertSummary.framework).then(function (response) {
Expand Down Expand Up @@ -64,10 +64,10 @@ perf.controller(
}]);

perf.controller(
'MarkDownstreamAlertsCtrl', ['$scope', '$uibModalInstance', '$http', '$q', 'alertSummary',
'allAlertSummaries', 'PhAlerts', 'phAlertStatusMap',
function ($scope, $uibModalInstance, $http, $q, alertSummary, allAlertSummaries,
PhAlerts, phAlertStatusMap) {
'MarkDownstreamAlertsCtrl', ['$scope', '$uibModalInstance', '$q', 'alertSummary',
'allAlertSummaries', 'phAlertStatusMap',
function ($scope, $uibModalInstance, $q, alertSummary, allAlertSummaries,
phAlertStatusMap) {
$scope.title = "Mark alerts downstream";
$scope.placeholder = "Alert #";

Expand Down Expand Up @@ -102,9 +102,9 @@ perf.controller(
}]);

perf.controller(
'ReassignAlertsCtrl', ['$scope', '$uibModalInstance', '$http', '$q', 'alertSummary',
'allAlertSummaries', 'PhAlerts', 'phAlertStatusMap',
function ($scope, $uibModalInstance, $http, $q, alertSummary, allAlertSummaries, PhAlerts, phAlertStatusMap) {
'ReassignAlertsCtrl', ['$scope', '$uibModalInstance', '$q', 'alertSummary',
'allAlertSummaries', 'phAlertStatusMap',
function ($scope, $uibModalInstance, $q, alertSummary, allAlertSummaries, phAlertStatusMap) {

$scope.title = "Reassign alerts";
$scope.placeholder = "Alert #";
Expand Down Expand Up @@ -142,17 +142,17 @@ perf.controller(
}]);

perf.controller('AlertsCtrl', [
'$state', '$stateParams', '$scope', '$rootScope', '$http', '$q', '$uibModal',
'$state', '$stateParams', '$scope', '$rootScope', '$q', '$uibModal',
'thUrl', 'ThRepositoryModel', 'ThOptionCollectionModel',
'ThResultSetModel',
'PhFramework', 'PhSeries', 'PhAlerts', 'PhBugs', 'phTimeRanges',
'PhFramework', 'PhAlerts', 'PhBugs', 'phTimeRanges',
'phDefaultTimeRangeValue', 'phAlertSummaryStatusMap', 'phAlertStatusMap',
'dateFilter', 'thDateFormat', 'clipboard', 'phTimeRangeValues',
function AlertsCtrl($state, $stateParams, $scope, $rootScope, $http, $q,
function AlertsCtrl($state, $stateParams, $scope, $rootScope, $q,
$uibModal,
thUrl, ThRepositoryModel,
ThOptionCollectionModel, ThResultSetModel,
PhFramework, PhSeries, PhAlerts, PhBugs, phTimeRanges,
PhFramework, PhAlerts, PhBugs, phTimeRanges,
phDefaultTimeRangeValue, phAlertSummaryStatusMap, phAlertStatusMap,
dateFilter, thDateFormat, clipboard, phTimeRangeValues) {
$scope.alertSummaries = undefined;
Expand Down
28 changes: 12 additions & 16 deletions ui/js/controllers/perf/compare.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,11 @@
perf.controller('CompareChooserCtrl', [
'$state', '$stateParams', '$scope', '$q', 'ThRepositoryModel', 'ThResultSetModel',
'phCompareDefaultNewRepo', 'phCompareDefaultOriginalRepo',
'thPerformanceBranches', 'localStorageService', 'compareBaseLineDefaultTimeRange',
'localStorageService', 'compareBaseLineDefaultTimeRange',
function CompareChooserCtrl($state, $stateParams, $scope, $q,
ThRepositoryModel, ThResultSetModel,
phCompareDefaultNewRepo,
phCompareDefaultOriginalRepo,
thPerformanceBranches,
localStorageService,
compareBaseLineDefaultTimeRange) {
ThRepositoryModel.get_list().success(function (projects) {
Expand Down Expand Up @@ -118,15 +117,13 @@ perf.controller('CompareChooserCtrl', [
}]);

perf.controller('CompareResultsCtrl', [
'$state', '$stateParams', '$scope', '$rootScope', '$location',
'thServiceDomain', 'ThRepositoryModel',
'ThResultSetModel', '$http', '$httpParamSerializer', '$q', '$timeout', 'PhFramework', 'PhSeries',
'math', 'phTimeRanges', 'PhCompare', 'compareBaseLineDefaultTimeRange',
'$state', '$stateParams', '$scope',
'ThRepositoryModel',
'ThResultSetModel', '$httpParamSerializer', '$q', 'PhFramework', 'PhSeries',
'phTimeRanges', 'PhCompare', 'compareBaseLineDefaultTimeRange',
function CompareResultsCtrl($state, $stateParams, $scope,
$rootScope, $location,
thServiceDomain,
ThRepositoryModel, ThResultSetModel, $http, $httpParamSerializer,
$q, $timeout, PhFramework, PhSeries, math,
ThRepositoryModel, ThResultSetModel, $httpParamSerializer,
$q, PhFramework, PhSeries,
phTimeRanges,
PhCompare, compareBaseLineDefaultTimeRange) {
function displayResults(rawResultsMap, newRawResultsMap) {
Expand Down Expand Up @@ -482,14 +479,13 @@ perf.controller('CompareResultsCtrl', [
}]);

perf.controller('CompareSubtestResultsCtrl', [
'$state', '$stateParams', '$scope', '$rootScope', '$location',
'thServiceDomain', 'ThRepositoryModel',
'ThResultSetModel', '$http', '$q', '$timeout', 'PhSeries', 'math',
'$state', '$stateParams', '$scope',
'ThRepositoryModel',
'ThResultSetModel', '$q', 'PhSeries',
'PhCompare', 'phTimeRanges', 'compareBaseLineDefaultTimeRange', '$httpParamSerializer',
function CompareSubtestResultsCtrl($state, $stateParams, $scope, $rootScope,
$location, thServiceDomain,
function CompareSubtestResultsCtrl($state, $stateParams, $scope,
ThRepositoryModel, ThResultSetModel,
$http, $q, $timeout, PhSeries, math,
$q, PhSeries,
PhCompare, phTimeRanges, compareBaseLineDefaultTimeRange,
$httpParamSerializer) {
//TODO: duplicated from comparectrl
Expand Down
8 changes: 4 additions & 4 deletions ui/js/controllers/perf/dashboard.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@
perf.value('defaultTimeRange', 86400 * 2);

perf.controller('dashCtrl', [
'$state', '$stateParams', '$scope', '$rootScope', '$q', '$http', '$httpParamSerializer',
'$state', '$stateParams', '$scope', '$rootScope', '$q', '$httpParamSerializer',
'ThRepositoryModel', 'ThResultSetModel', 'PhSeries', 'PhCompare',
'thDefaultRepo', 'phTimeRanges', 'defaultTimeRange', 'phBlockers', 'phDashboardValues',
function dashCtrl($state, $stateParams, $scope, $rootScope, $q, $http, $httpParamSerializer,
function dashCtrl($state, $stateParams, $scope, $rootScope, $q, $httpParamSerializer,
ThRepositoryModel, ThResultSetModel, PhSeries, PhCompare,
thDefaultRepo, phTimeRanges,
defaultTimeRange, phBlockers, phDashboardValues) {
Expand Down Expand Up @@ -213,10 +213,10 @@ perf.controller('dashCtrl', [
]);

perf.controller('dashSubtestCtrl', [
'$state', '$stateParams', '$scope', '$rootScope', '$q', '$http',
'$state', '$stateParams', '$scope', '$rootScope', '$q',
'ThRepositoryModel', 'ThResultSetModel', 'PhSeries', 'PhCompare',
'thDefaultRepo', 'phTimeRanges', 'defaultTimeRange', 'phDashboardValues',
function ($state, $stateParams, $scope, $rootScope, $q, $http,
function ($state, $stateParams, $scope, $rootScope, $q,
ThRepositoryModel, ThResultSetModel, PhSeries, PhCompare,
thDefaultRepo, phTimeRanges, defaultTimeRange,
phDashboardValues) {
Expand Down
26 changes: 13 additions & 13 deletions ui/js/controllers/perf/e10s-trend.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@ perf.value('defaultNewDate', 0);
perf.value('defaultSampleSize', 604800);

perf.controller('e10sTrendCtrl', [
'$state', '$stateParams', '$scope', '$rootScope', '$q', '$http', '$httpParamSerializer',
'ThRepositoryModel', 'ThResultSetModel', 'PhSeries', 'PhCompare',
'thServiceDomain', 'thDefaultRepo', 'phTimeRanges', 'defaultSampleSize',
'$state', '$stateParams', '$scope', '$rootScope', '$q', '$httpParamSerializer',
'ThRepositoryModel', 'PhSeries', 'PhCompare',
'thDefaultRepo', 'phTimeRanges', 'defaultSampleSize',
'phComparisonDate', 'defaultBaseDate', 'defaultNewDate', 'phBlockers',
function e10sTrendCtrl($state, $stateParams, $scope, $rootScope, $q, $http, $httpParamSerializer,
ThRepositoryModel, ThResultSetModel, PhSeries, PhCompare,
thServiceDomain, thDefaultRepo, phTimeRanges,
function e10sTrendCtrl($state, $stateParams, $scope, $rootScope, $q, $httpParamSerializer,
ThRepositoryModel, PhSeries, PhCompare,
thDefaultRepo, phTimeRanges,
defaultSampleSize, phComparisonDate, defaultBaseDate, defaultNewDate, phBlockers) {

$scope.compareResults = {};
Expand Down Expand Up @@ -253,13 +253,13 @@ perf.controller('e10sTrendCtrl', [
]);

perf.controller('e10sTrendSubtestCtrl', [
'$state', '$stateParams', '$scope', '$rootScope', '$q', '$http', '$httpParamSerializer',
'ThRepositoryModel', 'ThResultSetModel', 'PhSeries', 'PhCompare',
'thServiceDomain', 'thDefaultRepo', 'phTimeRanges', 'defaultSampleSize',
'phComparisonDate', 'defaultBaseDate', 'defaultNewDate', 'phBlockers',
function e10sTrendCtrl($state, $stateParams, $scope, $rootScope, $q, $http, $httpParamSerializer,
ThRepositoryModel, ThResultSetModel, PhSeries, PhCompare,
thServiceDomain, thDefaultRepo, phTimeRanges,
'$state', '$stateParams', '$scope', '$rootScope', '$q',
'ThRepositoryModel', 'PhSeries', 'PhCompare',
'thDefaultRepo', 'phTimeRanges', 'defaultSampleSize',
'phComparisonDate', 'defaultBaseDate', 'defaultNewDate',
function e10sTrendCtrl($state, $stateParams, $scope, $rootScope, $q,
ThRepositoryModel, PhSeries, PhCompare,
thDefaultRepo, phTimeRanges,
defaultSampleSize, phComparisonDate, defaultBaseDate, defaultNewDate) {

var baseSignature = $stateParams.baseSignature;
Expand Down
14 changes: 7 additions & 7 deletions ui/js/controllers/perf/graphs.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
"use strict";

perf.controller('GraphsCtrl', [
'$state', '$stateParams', '$scope', '$rootScope', '$location', '$uibModal',
'$window', 'thServiceDomain', '$http', '$q', '$timeout', 'PhSeries', 'PhAlerts',
'$state', '$stateParams', '$scope', '$rootScope', '$uibModal',
'$window', 'thServiceDomain', '$q', '$timeout', 'PhSeries', 'PhAlerts',
'ThRepositoryModel', 'ThResultSetModel', 'phTimeRanges', 'phDefaultTimeRangeValue',
function GraphsCtrl($state, $stateParams, $scope, $rootScope, $location,
$uibModal, $window, thServiceDomain, $http, $q, $timeout, PhSeries,
function GraphsCtrl($state, $stateParams, $scope, $rootScope,
$uibModal, $window, thServiceDomain, $q, $timeout, PhSeries,
PhAlerts, ThRepositoryModel, ThResultSetModel,
phTimeRanges, phDefaultTimeRangeValue) {
var availableColors = ['maroon', 'navy', 'pink', 'turquoise', 'brown',
Expand Down Expand Up @@ -876,11 +876,11 @@ perf.filter('testNameContainsWords', function () {
};
});

perf.controller('TestChooserCtrl', ['$scope', '$uibModalInstance', '$http',
'projects', 'timeRange', 'thServiceDomain', 'thDefaultRepo', 'PhSeries',
perf.controller('TestChooserCtrl', ['$scope', '$uibModalInstance',
'projects', 'timeRange', 'thDefaultRepo', 'PhSeries',
'PhFramework', 'defaultFrameworkId', 'defaultProjectName', 'defaultPlatform',
'$q', 'testsDisplayed', 'options', 'thPerformanceBranches', 'phDefaultFramework',
function ($scope, $uibModalInstance, $http, projects, timeRange, thServiceDomain,
function ($scope, $uibModalInstance, projects, timeRange,
thDefaultRepo, PhSeries, PhFramework, defaultFrameworkId, defaultProjectName,
defaultPlatform, $q, testsDisplayed, options, thPerformanceBranches,
phDefaultFramework) {
Expand Down
8 changes: 4 additions & 4 deletions ui/js/controllers/tcjobactions.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
"use strict";

treeherder.controller('TCJobActionsCtrl', [
'$scope', '$http', '$uibModalInstance', 'ThResultSetStore',
'ThJobDetailModel', 'thTaskcluster', 'ThTaskclusterErrors',
'$scope', '$uibModalInstance', 'ThResultSetStore',
'thTaskcluster', 'ThTaskclusterErrors',
'thNotify', 'job', 'repoName', 'resultsetId', 'tcactions',
'jsyaml', 'Ajv', 'jsonSchemaDefaults',
function ($scope, $http, $uibModalInstance, ThResultSetStore,
ThJobDetailModel, thTaskcluster, ThTaskclusterErrors, thNotify,
function ($scope, $uibModalInstance, ThResultSetStore,
thTaskcluster, ThTaskclusterErrors, thNotify,
job, repoName, resultsetId, tcactions, jsyaml, Ajv, jsonSchemaDefaults) {
const ajv = new Ajv({ format: 'full', verbose: true, allErrors: true });
let decisionTaskId;
Expand Down
6 changes: 3 additions & 3 deletions ui/js/directives/treeherder/bottom_nav_panel.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@ treeherder.directive('thRelatedBugQueued', function () {
});

treeherder.directive('thFailureClassification', [
'$parse', 'thClassificationTypes',
function ($parse, thClassificationTypes) {
'thClassificationTypes',
function (thClassificationTypes) {
return {
scope: {
failureId: "=",
Expand All @@ -63,7 +63,7 @@ treeherder.directive('thFailureClassification', [
}]);

treeherder.directive('thSimilarJobs', [
'ThJobModel', 'ThLog',
'ThJobModel',
function (ThJobModel) {
return {
restrict: "E",
Expand Down
Loading