remove unused injected dependencies (#36854) (#36887)

Remove unused injected dependencies to make dependency analysis possible. Part of a series of PRs
This commit is contained in:
Matthew Kime 2019-05-24 00:01:20 -05:00 committed by GitHub
parent 3ffd120af3
commit 7dfa979f6e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 7 additions and 8 deletions

View file

@ -28,7 +28,7 @@ describe('Date Format', function () {
let off;
beforeEach(ngMock.module('kibana'));
beforeEach(ngMock.inject(function (Private, config, $rootScope) {
beforeEach(ngMock.inject(function (config, $rootScope) {
$scope = $rootScope;
settings = config;

View file

@ -39,7 +39,7 @@ const homeTitle = i18n.translate('kbn.home.breadcrumbs.homeTitle', { defaultMess
function getRoute() {
return {
template,
controller($scope, config, indexPatterns, Private) {
controller($scope, Private) {
$scope.directories = Private(FeatureCatalogueRegistryProvider).inTitleOrder;
$scope.recentlyAccessed = recentlyAccessed.get().map(item => {
item.link = chrome.addBasePath(item.link);

View file

@ -127,7 +127,7 @@ export const destroyReact = id => {
uiModules
.get('apps/management')
.directive('kbnManagementApp', function (Private, $location) {
.directive('kbnManagementApp', function ($location) {
return {
restrict: 'E',
template: appTemplate,

View file

@ -23,7 +23,7 @@ import { I18nContext } from 'ui/i18n';
import chrome from 'ui/chrome';
import { fetchIndexPatternFields } from '../lib/fetch_fields';
function ReactEditorControllerProvider(Private, config) {
function ReactEditorControllerProvider(config) {
class ReactEditorController {
constructor(el, savedObj) {
this.el = el;

View file

@ -27,7 +27,7 @@ import { getFormat } from 'ui/visualize/loader/pipeline_helpers/utilities';
uiModules
.get('kibana', ['RecursionHelper'])
.directive('kbnAggTable', function ($filter, config, Private, RecursionHelper) {
.directive('kbnAggTable', function (config, RecursionHelper) {
return {
restrict: 'E',

View file

@ -29,7 +29,7 @@ import { Status } from 'ui/vis/update_status';
import { truncatedColorMaps } from 'ui/vislib/components/color/truncated_colormaps';
import { convertToGeoJson } from 'ui/vis/map/convert_to_geojson';
VisTypesRegistryProvider.register(function TileMapVisType(Private, getAppState, courier, config) {
VisTypesRegistryProvider.register(function TileMapVisType(Private, config) {
const VisFactory = Private(VisFactoryProvider);
const CoordinateMapsVisualization = Private(CoordinateMapsVisualizationProvider);

View file

@ -119,7 +119,6 @@ app.controller('timelion', function (
AppState,
config,
confirmModal,
courier,
kbnUrl,
Notifier,
Private

View file

@ -23,7 +23,7 @@ const app = require('ui/modules').get('apps/timelion', []);
app.directive('fixedElementRoot', function () {
return {
restrict: 'A',
link: function ($scope, $elem) {
link: function ($elem) {
let fixedAt;
$(window).bind('scroll', function () {
const fixed = $('[fixed-element]', $elem);