mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-21 20:47:08 -05:00
changed :project_id to :Project_id
This commit is contained in:
parent
0aa6a206e7
commit
9f82e63a8f
3 changed files with 5 additions and 5 deletions
|
@ -6,7 +6,7 @@ module.exports =
|
||||||
|
|
||||||
|
|
||||||
sendMessage: (req, res)->
|
sendMessage: (req, res)->
|
||||||
{project_id} = req.params
|
project_id = req.params.Project_id
|
||||||
user_id = req.session.user._id
|
user_id = req.session.user._id
|
||||||
messageContent = req.body.content
|
messageContent = req.body.content
|
||||||
ChatHandler.sendMessage project_id, user_id, messageContent, (err, builtMessge)->
|
ChatHandler.sendMessage project_id, user_id, messageContent, (err, builtMessge)->
|
||||||
|
@ -17,7 +17,7 @@ module.exports =
|
||||||
res.send()
|
res.send()
|
||||||
|
|
||||||
getMessages: (req, res)->
|
getMessages: (req, res)->
|
||||||
{project_id} = req.params
|
project_id = req.params.Project_id
|
||||||
query = req.body
|
query = req.body
|
||||||
logger.log project_id:project_id, query:query, "getting messages"
|
logger.log project_id:project_id, query:query, "getting messages"
|
||||||
ChatHandler.getMessages project_id, query, (err, messages)->
|
ChatHandler.getMessages project_id, query, (err, messages)->
|
||||||
|
|
|
@ -160,8 +160,8 @@ module.exports = class Router
|
||||||
app.post "/spelling/check", AuthenticationController.requireLogin(), SpellingController.proxyRequestToSpellingApi
|
app.post "/spelling/check", AuthenticationController.requireLogin(), SpellingController.proxyRequestToSpellingApi
|
||||||
app.post "/spelling/learn", AuthenticationController.requireLogin(), SpellingController.proxyRequestToSpellingApi
|
app.post "/spelling/learn", AuthenticationController.requireLogin(), SpellingController.proxyRequestToSpellingApi
|
||||||
|
|
||||||
app.get "/project/:project_id/messages", SecurityManager.requestCanAccessProject, ChatController.getMessages
|
app.get "/project/:Project_id/messages", SecurityManager.requestCanAccessProject, ChatController.getMessages
|
||||||
app.post "/project/:project_id/messages", SecurityManager.requestCanAccessProject, ChatController.sendMessage
|
app.post "/project/:Project_id/messages", SecurityManager.requestCanAccessProject, ChatController.sendMessage
|
||||||
|
|
||||||
#Admin Stuff
|
#Admin Stuff
|
||||||
app.get '/admin', SecurityManager.requestIsAdmin, AdminController.index
|
app.get '/admin', SecurityManager.requestIsAdmin, AdminController.index
|
||||||
|
|
|
@ -27,7 +27,7 @@ describe "ChatController", ->
|
||||||
|
|
||||||
@req =
|
@req =
|
||||||
params:
|
params:
|
||||||
project_id:@project_id
|
Project_id:@project_id
|
||||||
session:
|
session:
|
||||||
user:
|
user:
|
||||||
_id:@user_id
|
_id:@user_id
|
||||||
|
|
Loading…
Reference in a new issue