From b367cc0ca28de6b4e735939b1981668ff21b8ecf Mon Sep 17 00:00:00 2001 From: Phil Hughes Date: Tue, 30 Jan 2018 09:10:58 +0000 Subject: [PATCH] potential fix for tests crashing use underscore noop instead of jquery --- app/assets/javascripts/api.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/app/assets/javascripts/api.js b/app/assets/javascripts/api.js index 2fddd6b0ed4..1f34c6b50c2 100644 --- a/app/assets/javascripts/api.js +++ b/app/assets/javascripts/api.js @@ -1,8 +1,9 @@ +import _ from 'underscore'; import axios from './lib/utils/axios_utils'; const Api = { groupsPath: '/api/:version/groups.json', - groupPath: '/api/:version/groups/:id.json', + groupPath: '/api/:version/groups/:id', namespacesPath: '/api/:version/namespaces.json', groupProjectsPath: '/api/:version/groups/:id/projects.json', projectsPath: '/api/:version/projects.json', @@ -59,7 +60,7 @@ const Api = { }, // Return projects list. Filtered by query - projects(query, options, callback = $.noop) { + projects(query, options, callback = _.noop) { const url = Api.buildUrl(Api.projectsPath); const defaults = { search: query,