Fixed bug in fetching submitted ladder sessions that hadn't been scored yet.

This commit is contained in:
Nick Winter 2014-10-20 17:00:46 -07:00
parent bc15ccd240
commit 700b460f91

View file

@ -30,7 +30,7 @@ class LevelSessionHandler extends Handler
@sendSuccess(res, documents) @sendSuccess(res, documents)
hasAccessToDocument: (req, document, method=null) -> hasAccessToDocument: (req, document, method=null) ->
return true if req.method is 'GET' and document.get('totalScore') return true if req.method is 'GET' and document.get('submitted')
return true if ('employer' in (req.user.get('permissions') ? [])) and (method ? req.method).toLowerCase() is 'get' return true if ('employer' in (req.user.get('permissions') ? [])) and (method ? req.method).toLowerCase() is 'get'
super(arguments...) super(arguments...)