mirror of
https://github.com/yu-i-i/overleaf-cep.git
synced 2026-06-06 15:49:01 +02:00
Fix comically long lines.
This commit is contained in:
@@ -13,7 +13,11 @@ module.exports = ReferencesSearchController =
|
||||
if !doc_id
|
||||
logger.log project_id: project_id, "no fileUrl supplied"
|
||||
return res.send 400
|
||||
ProjectLocator.findElement {project_id: project_id, element_id: doc_id, type: 'doc'}, (err, doc) ->
|
||||
ProjectLocator.findElement {
|
||||
project_id: project_id,
|
||||
element_id: doc_id,
|
||||
type: 'doc'
|
||||
}, (err, doc) ->
|
||||
if err?
|
||||
logger.err {err, project_id, doc_id}, "error finding doc to index"
|
||||
return res.send 500
|
||||
|
||||
+2
-1
@@ -57,7 +57,8 @@ describe "ReferencesSearchController", ->
|
||||
@res.send = (status) =>
|
||||
@ReferencesSearchHandler.indexFile.calledOnce.should.equal true
|
||||
expected_url = "http://some.url/project/2222/doc/3333"
|
||||
@ReferencesSearchHandler.indexFile.calledWith(@project_id, expected_url).should.equal true
|
||||
@ReferencesSearchHandler.indexFile
|
||||
.calledWith(@project_id, expected_url).should.equal true
|
||||
done()
|
||||
@controller.indexFile(@req, @res)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user