.
This commit is contained in:
parent
d39148cac3
commit
a4d1bd345d
@ -5,7 +5,7 @@ export default {
|
|||||||
preset: "ts-jest",
|
preset: "ts-jest",
|
||||||
testEnvironment: "node",
|
testEnvironment: "node",
|
||||||
rootDir: "./",
|
rootDir: "./",
|
||||||
testMatch: ["**/*.spec.ts"],
|
testMatch: ["**/*.test.ts", "**/*.spec.ts"],
|
||||||
moduleFileExtensions: ["ts", "tsx", "js", "jsx", "json", "node"],
|
moduleFileExtensions: ["ts", "tsx", "js", "jsx", "json", "node"],
|
||||||
moduleNameMapper: pathsToModuleNameMapper(compilerOptions.paths, { prefix: "<rootDir>/src/" }),
|
moduleNameMapper: pathsToModuleNameMapper(compilerOptions.paths, { prefix: "<rootDir>/src/" }),
|
||||||
transform: {
|
transform: {
|
||||||
|
|||||||
@ -73,6 +73,7 @@ export class AccountService implements IAccountService {
|
|||||||
|
|
||||||
async activateAccount(id: UniqueID, transaction?: Transaction): Promise<Result<Account, Error>> {
|
async activateAccount(id: UniqueID, transaction?: Transaction): Promise<Result<Account, Error>> {
|
||||||
const accountOrError = await this.repo.findById(id, transaction);
|
const accountOrError = await this.repo.findById(id, transaction);
|
||||||
|
|
||||||
if (accountOrError.isFailure) {
|
if (accountOrError.isFailure) {
|
||||||
return Result.fail(new Error("Account not found"));
|
return Result.fail(new Error("Account not found"));
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user