From 7a86f754dfba67bf395df7158a3252997e411c92 Mon Sep 17 00:00:00 2001 From: Rob Date: Tue, 17 Nov 2015 11:27:08 -0800 Subject: [PATCH] Add flavor to overworld. --- app/views/play/CampaignView.coffee | 2 +- server/campaigns/campaign_handler.coffee | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/app/views/play/CampaignView.coffee b/app/views/play/CampaignView.coffee index eccba8c54..18e475f3f 100644 --- a/app/views/play/CampaignView.coffee +++ b/app/views/play/CampaignView.coffee @@ -33,7 +33,7 @@ class LevelSessionsCollection extends CocoCollection @url = "/db/user/#{me.id}/level.sessions?project=state.complete,levelID,state.difficulty,playtime" class CampaignsCollection extends CocoCollection - url: '/db/campaign/-/overview' + url: '/db/campaign/-/overworld' model: Campaign project: ['name', 'fullName', 'description', 'i18n'] diff --git a/server/campaigns/campaign_handler.coffee b/server/campaigns/campaign_handler.coffee index 08bfe6623..31f8c5806 100644 --- a/server/campaigns/campaign_handler.coffee +++ b/server/campaigns/campaign_handler.coffee @@ -52,7 +52,7 @@ CampaignHandler = class CampaignHandler extends Handler documents = (@formatEntity(req, doc) for doc in documents) @sendSuccess(res, documents) - getOverview: (req, res) -> + getOverworld: (req, res) -> return @sendForbiddenError(res) if not @hasAccess(req) q = @modelClass.find {}, slug: 1, adjacentCampaigns: 1, fullName: 1, description: 1, color: 1 q.exec (err, documents) => @@ -66,7 +66,7 @@ CampaignHandler = class CampaignHandler extends Handler getByRelationship: (req, res, args...) -> relationship = args[1] - return @getOverview(req,res) if args[0] is '-' and relationship is 'overview' + return @getOverworld(req,res) if args[0] is '-' and relationship is 'overworld' if relationship in ['levels', 'achievements'] projection = {}