mirror of
https://github.com/yu-i-i/overleaf-cep.git
synced 2026-11-14 06:03:45 +01:00
changed key for templates to put /v/ in for version
This commit is contained in:
@@ -25,7 +25,7 @@ module.exports =
|
||||
|
||||
templateFileKey: (req, res, next)->
|
||||
{template_id, format, version} = req.params
|
||||
req.key = "#{template_id}/#{version}/#{format}"
|
||||
req.key = "#{template_id}/v/#{version}/#{format}"
|
||||
req.bucket = settings.filestore.stores.template_files
|
||||
req.version = version
|
||||
opts = req.query
|
||||
|
||||
@@ -70,7 +70,6 @@ describe "FileController", ->
|
||||
done()
|
||||
@controller.getFile @req, @res
|
||||
|
||||
|
||||
describe "insertFile", ->
|
||||
|
||||
it "should send bucket name key and res to PersistorManager", (done)->
|
||||
@@ -79,7 +78,6 @@ describe "FileController", ->
|
||||
@FileHandler.insertFile.calledWith(@bucket, @key, @req).should.equal true
|
||||
done()
|
||||
@controller.insertFile @req, @res
|
||||
|
||||
|
||||
describe "copyFile", ->
|
||||
beforeEach ->
|
||||
@@ -98,7 +96,6 @@ describe "FileController", ->
|
||||
done()
|
||||
@controller.copyFile @req, @res
|
||||
|
||||
|
||||
it "should send a 500 if there was an error", (done)->
|
||||
@PersistorManager.copyFile.callsArgWith(3, "error")
|
||||
@res.send = (code)=>
|
||||
@@ -106,7 +103,6 @@ describe "FileController", ->
|
||||
done()
|
||||
@controller.copyFile @req, @res
|
||||
|
||||
|
||||
describe "delete file", ->
|
||||
|
||||
it "should tell the file handler", (done)->
|
||||
|
||||
Reference in New Issue
Block a user