timi-codes/Banka

View on GitHub
API/services/user.service.js

Summary

Maintainability
A
1 hr
Test Coverage

Showing 1 of 3 total issues

Function signUser has 36 lines of code (exceeds 30 allowed). Consider refactoring.
Open

static async signUser(login) {
try {
const user = await User.findUserByEmail(login.email);
 
if (user) {
Severity: Minor
Found in API/services/user.service.js - About 1 hr to fix

    Function createUser has 32 lines of code (exceeds 30 allowed). Consider refactoring.
    Wontfix

    static async createUser(user) {
    try {
    const isUser = await User.findUserByEmail(user.email);
     
    if (isUser) {
    Severity: Minor
    Found in API/services/user.service.js - About 1 hr to fix

      Function createAStaff has 32 lines of code (exceeds 30 allowed). Consider refactoring.
      Invalid

      static async createAStaff(user) {
      try {
      const isStaff = await User.findUserByEmail(user.email);
       
      if (isStaff) {
      Severity: Minor
      Found in API/services/user.service.js - About 1 hr to fix

        There are no issues that match your filters.

        Category
        Status