WIP(customizations): revised backgrounds modal

This commit is contained in:
Sabe Jones
2024-04-17 18:02:35 -05:00
parent 4277c08324
commit 5f64b2fb25
3 changed files with 49 additions and 189 deletions

View File

@@ -224,7 +224,7 @@ export default async function unlock (user, req = {}, analytics) {
// The passed paths are not used anymore after this point for full sets
const { set, items, paths } = getSet(setType, firstPath, req);
if (isBackground) {
if (isBackground && !alreadyUnlocked(user, setType, path)) {
const matchers = getScheduleMatchingGroup('backgrounds');
if (!matchers.match(set.key)) {
throw new NotAuthorized(i18n.t('notAvailable', req.language));