Skip to content

Commit

Permalink
Fix: remove unused imports
Browse files Browse the repository at this point in the history
  • Loading branch information
alexanderleegs committed Oct 5, 2022
1 parent 307ecc3 commit 78bc0ae
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 15 deletions.
9 changes: 1 addition & 8 deletions src/routes/v2/authenticatedSites/notifications.ts
Original file line number Diff line number Diff line change
@@ -1,20 +1,13 @@
import autoBind from "auto-bind"
import express from "express"
import validator from "validator"

import logger from "@logger/logger"

import { BadRequestError } from "@errors/BadRequestError"

import {
attachReadRouteHandlerWrapper,
attachWriteRouteHandlerWrapper,
} from "@middleware/routeHandler"

import UserSessionData from "@classes/UserSessionData"

import UserWithSiteSessionData from "@root/classes/UserWithSiteSessionData"
import { isError, RequestHandler } from "@root/types"
import { RequestHandler } from "@root/types"
import NotificationsService from "@services/identity/NotificationsService"

interface NotificationsRouterProps {
Expand Down
8 changes: 2 additions & 6 deletions src/services/identity/NotificationsService.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { ModelStatic, Op, Sequelize } from "sequelize"
import { ModelStatic, Op } from "sequelize"

import { Notification, Site, Repo, SiteMember } from "@database/models"
import {
Expand All @@ -12,7 +12,6 @@ const NUM_RECENT_NOTIFICATIONS = 6

interface NotificationsServiceProps {
repository: ModelStatic<Notification>
site: ModelStatic<Site>
siteMember: ModelStatic<SiteMember>
}

Expand All @@ -21,13 +20,10 @@ class NotificationsService {
// that the types are synced.
private readonly repository: NotificationsServiceProps["repository"]

private readonly site: NotificationsServiceProps["site"]

private readonly siteMember: NotificationsServiceProps["siteMember"]

constructor({ repository, site, siteMember }: NotificationsServiceProps) {
constructor({ repository, siteMember }: NotificationsServiceProps) {
this.repository = repository
this.site = site
this.siteMember = siteMember
}

Expand Down
1 change: 0 additions & 1 deletion src/services/identity/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,5 @@ export const isomerAdminsService = new IsomerAdminsService({

export const notificationsService = new NotificationsService({
repository: Notification,
site: Site,
siteMember: SiteMember,
})

0 comments on commit 78bc0ae

Please sign in to comment.