Removed v2 calls from views (#7351)

This commit is contained in:
Keith Holliday
2016-05-18 16:48:32 +01:00
committed by Matteo Pagliazzi
parent 58b9a08539
commit 425172daae
4 changed files with 7 additions and 7 deletions

View File

@@ -1,4 +1,4 @@
import { authWithHeaders } from '../../middlewares/api-v3/auth';
import { authWithHeaders, authWithSession } from '../../middlewares/api-v3/auth';
import _ from 'lodash';
import { model as Challenge } from '../../models/challenge';
import {
@@ -340,7 +340,7 @@ api.getChallenge = {
api.exportChallengeCsv = {
method: 'GET',
url: '/challenges/:challengeId/export/csv',
middlewares: [authWithHeaders()],
middlewares: [authWithSession],
async handler (req, res) {
req.checkParams('challengeId', res.t('challengeIdRequired')).notEmpty().isUUID();