removed some unused code

This commit is contained in:
Sascha Kühl 2025-05-25 15:46:10 +02:00
parent 7465e9500c
commit c5e38c8f39
5 changed files with 2 additions and 5 deletions

View File

@ -58,6 +58,6 @@ exports.findOne = (req, res) => {
res.status(404).send({message: `Cannot find user with id=${id}.`}); res.status(404).send({message: `Cannot find user with id=${id}.`});
} }
}).catch(err => { }).catch(err => {
res.status(500).send({message: `Error retrieving user with id=${id}.`}); res.status(500).send({message: `Error retrieving user with id=${id} (${err.message}).`});
}); });
} }

View File

@ -1,5 +1,4 @@
const db = require("./models/index"); const db = require("./models/index");
const bcrypt = require("bcryptjs");
const { beforeAll, afterAll } = require('@jest/globals'); const { beforeAll, afterAll } = require('@jest/globals');

View File

@ -1,7 +1,7 @@
// Migration 2: Remove columns from Users // Migration 2: Remove columns from Users
/** @type {import('sequelize-cli').Migration} */ /** @type {import('sequelize-cli').Migration} */
module.exports = { module.exports = {
async up(queryInterface, Sequelize) { async up(queryInterface, /*Sequelize*/) {
await queryInterface.removeColumn('Users', 'height'); await queryInterface.removeColumn('Users', 'height');
await queryInterface.removeColumn('Users', 'weight'); await queryInterface.removeColumn('Users', 'weight');
await queryInterface.removeColumn('Users', 'gender'); await queryInterface.removeColumn('Users', 'gender');

View File

@ -1,4 +1,3 @@
const bcrypt = require("bcryptjs");
const process = require('process'); const process = require('process');
const {createPlayer, createUsers} = require("../helper/seeder.helper"); const {createPlayer, createUsers} = require("../helper/seeder.helper");

View File

@ -8,7 +8,6 @@ const {
const app = require("../app") const app = require("../app")
const { signupPlayer } = require("./data/player.test.data") const { signupPlayer } = require("./data/player.test.data")
const {set} = require("express/lib/application");
describe("Test player creation, authentication and retrieval", () => { describe("Test player creation, authentication and retrieval", () => {
test("should create a player", async () => { test("should create a player", async () => {