Fixes #12417
Squashed commit of the following:

commit 1f074175c480a638cf61e2c72ca57cdc6f8699b6
Author: Matteo Pagliazzi <matteopagliazzi@gmail.com>
Date:   Mon Oct 26 10:57:23 2020 +0100

    fix(i18n): remove unused string questLevelTooHigh

commit 12cc74002ec87c14cc000b008454f34475fd3636
Merge: 4fc260e552 ad9b551de3
Author: Matteo Pagliazzi <matteopagliazzi@gmail.com>
Date:   Mon Oct 26 10:50:39 2020 +0100

    Merge branch 'feature/level-locked-quests-should-be-used-at-any-level' of https://github.com/hamboomger/habitica into hamboomger-feature/level-locked-quests-should-be-used-at-any-level

commit ad9b551de3
Author: hamboomger <hamboomger@gmail.com>
Date:   Thu Oct 8 13:34:19 2020 +0300

    fix(quests): Quests that are level-locked for purchase can now be used at any level
This commit is contained in:
Matteo Pagliazzi
2020-10-26 10:58:50 +01:00
parent 734e997345
commit 869d2df4fa
79 changed files with 12 additions and 94 deletions

View File

@@ -73,7 +73,6 @@ api.inviteToQuest = {
if (group.type !== 'party') throw new NotAuthorized(res.t('guildQuestsNotSupported'));
if (!quest) throw new NotFound(apiError('questNotFound', { key: questKey }));
if (!user.items.quests[questKey]) throw new NotAuthorized(res.t('questNotOwned'));
if (user.stats.lvl < quest.lvl) throw new NotAuthorized(res.t('questLevelTooHigh', { level: quest.lvl }));
if (group.quest.key) throw new NotAuthorized(res.t('questAlreadyUnderway'));
const members = await User.find({