mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-21 20:47:08 -05:00
Add configurable max_doc_length
This commit is contained in:
parent
29c812cece
commit
27d3ebc1fd
2 changed files with 4 additions and 1 deletions
|
@ -19,7 +19,8 @@ app.use Metrics.http.monitor(logger)
|
|||
app.get '/project/:project_id/doc', HttpController.getAllDocs
|
||||
app.get '/project/:project_id/doc/:doc_id', HttpController.getDoc
|
||||
app.get '/project/:project_id/doc/:doc_id/raw', HttpController.getRawDoc
|
||||
app.post '/project/:project_id/doc/:doc_id', bodyParser.json(limit: "2mb"), HttpController.updateDoc
|
||||
# Add 16kb overhead for the JSON encoding
|
||||
app.post '/project/:project_id/doc/:doc_id', bodyParser.json(limit: Settings.max_doc_size + 16 * 1024), HttpController.updateDoc
|
||||
app.del '/project/:project_id/doc/:doc_id', HttpController.deleteDoc
|
||||
|
||||
app.post '/project/:project_id/archive', HttpController.archiveAllDocs
|
||||
|
|
|
@ -17,3 +17,5 @@ module.exports =
|
|||
# key: ""
|
||||
# secret: ""
|
||||
# bucket: "something"
|
||||
|
||||
max_doc_size: 2 * 1024 * 1024 # 2mb
|
||||
|
|
Loading…
Reference in a new issue