Small fixes

This commit is contained in:
Pitu 2019-03-14 23:14:24 +09:00
parent af9d752eaf
commit 79eb00f71c
5 changed files with 5 additions and 5 deletions

View File

@ -5,7 +5,7 @@ class userDisable extends Route {
super('/admin/users/disable', 'post', { adminOnly: true });
}
async run(req, res, db) {
async run(req, res, db, user) {
if (!req.body) return res.status(400).json({ message: 'No body provided' });
const { id } = req.body;
if (!id) return res.status(400).json({ message: 'No id provided' });

View File

@ -5,7 +5,7 @@ class userEnable extends Route {
super('/admin/users/enable', 'post', { adminOnly: true });
}
async run(req, res, db) {
async run(req, res, db, user) {
if (!req.body) return res.status(400).json({ message: 'No body provided' });
const { id } = req.body;
if (!id) return res.status(400).json({ message: 'No id provided' });

View File

@ -5,7 +5,7 @@ class userPromote extends Route {
super('/admin/users/promote', 'post', { adminOnly: true });
}
async run(req, res, db) {
async run(req, res, db, user) {
if (!req.body) return res.status(400).json({ message: 'No body provided' });
const { id } = req.body;
if (!id) return res.status(400).json({ message: 'No id provided' });

View File

@ -6,7 +6,7 @@ class albumGET extends Route {
super('/album/:id/full', 'get');
}
async run(req, res, db) {
async run(req, res, db, user) {
const { id } = req.params;
if (!id) return res.status(400).json({ message: 'Invalid id supplied' });

View File

@ -189,7 +189,7 @@
</div>
<div v-if="album.fileCount > 5"
class="thumb more no-background">
<router-link :to="`/dashboard/albums/${album.uuid}`">{{ album.fileCount - 5 }}+ more</router-link>
<router-link :to="`/dashboard/albums/${album.id}`">{{ album.fileCount - 5 }}+ more</router-link>
</div>
</template>
<template v-else>