You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

25 lines
618 B

'use strict';
const ServerError = require('../ServerError');
module.exports = class DatabaseInterface {
constructor() {
if (this.constructor === DatabaseInterface) {
throw new ServerError('Abstract class "DatabaseInterface" cannot be instantiated directly');
}
}
async initDb() {
throw new ServerError('You must implement this function');
}
async comparePassword(username, password) {
throw new ServerError('You must implement this function');
}
async updatePassword(username, oldPassword, newPassword) {
throw new ServerError('You must implement this function');
}
};