get next game from round proxy

This commit is contained in:
Thibault Duplessis 2019-08-20 10:18:18 +02:00
parent ff6c355683
commit 5d44201106
2 changed files with 2 additions and 2 deletions

View file

@ -125,7 +125,7 @@ object Round extends LilaController with TheftPrevention {
}
def next(gameId: String) = Auth { implicit ctx => me =>
OptionFuResult(GameRepo game gameId) { currentGame =>
OptionFuResult(env.proxy game gameId) { currentGame =>
otherPovs(currentGame) map getNext(currentGame) map {
_ orElse Pov(currentGame, me)
} flatMap {

View file

@ -161,7 +161,7 @@ object Setup extends LilaController with TheftPrevention {
NoPlaybanOrCurrent {
for {
config <- env.forms.hookConfig
game <- GameRepo.game(gameId)
game <- GameRepo game gameId
blocking <- ctx.userId ?? Env.relation.api.fetchBlocking
hookConfig = game.fold(config)(config.updateFrom)
sameOpponents = game.??(_.userIds)