add new lesson mode and started code refraction
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import { login, logout } from '../controllers/auth.controller.js';
|
||||
import { sync } from '../controllers/sync.controller.js';
|
||||
import { submitReview } from '../controllers/review.controller.js';
|
||||
import { getStats, getQueue, getCollection, updateSettings } from '../controllers/collection.controller.js';
|
||||
import { submitReview, submitLesson } from '../controllers/review.controller.js';
|
||||
import { getStats, getQueue, getLessonQueue, getCollection, updateSettings } from '../controllers/collection.controller.js';
|
||||
|
||||
async function routes(fastify, options) {
|
||||
fastify.post('/api/auth/login', login);
|
||||
@@ -12,8 +12,10 @@ async function routes(fastify, options) {
|
||||
privateParams.post('/api/auth/logout', logout);
|
||||
privateParams.post('/api/sync', sync);
|
||||
privateParams.post('/api/review', submitReview);
|
||||
privateParams.post('/api/lesson', submitLesson);
|
||||
privateParams.get('/api/stats', getStats);
|
||||
privateParams.get('/api/queue', getQueue);
|
||||
privateParams.get('/api/lessons', getLessonQueue);
|
||||
privateParams.get('/api/collection', getCollection);
|
||||
privateParams.post('/api/settings', updateSettings);
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user