Skip to content

Commit

Permalink
Merge pull request #44 from JHWelch/use-export-default
Browse files Browse the repository at this point in the history
use export default directly
  • Loading branch information
JHWelch authored Sep 2, 2023
2 parents 750fe26 + 503d717 commit f802b23
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 14 deletions.
4 changes: 1 addition & 3 deletions src/application.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import FirestoreAdapter from './data/firestore/firestoreAdapter.js'
import TmdbAdapter from './data/tmdb/tmdbAdapter.js'
import { registerRoutes } from './routes.js'

class Application {
export default class Application {
constructor (
private express: Express,
private firestore: FirestoreAdapter,
Expand All @@ -22,5 +22,3 @@ class Application {
})
}
}

export default Application
5 changes: 1 addition & 4 deletions src/controllers/dashboardController.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
/* eslint-disable @typescript-eslint/no-extraneous-class */
import { type Request, type Response } from 'express'

class DashboardController {
export default class DashboardController {
static PATHS = {
index: '/',
}
Expand All @@ -10,5 +9,3 @@ class DashboardController {
res.render('index', { path: DashboardController.PATHS.index })
}
}

export default DashboardController
5 changes: 1 addition & 4 deletions src/controllers/previousController.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
/* eslint-disable @typescript-eslint/no-extraneous-class */
import { type Request, type Response } from 'express'

class PreviousController {
export default class PreviousController {
static PATHS = {
index: '/previous',
}
Expand All @@ -10,5 +9,3 @@ class PreviousController {
res.render('previous/index', { path: PreviousController.PATHS.index })
}
}

export default PreviousController
4 changes: 1 addition & 3 deletions src/controllers/rsvpController.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import FirestoreAdapter from '../data/firestore/firestoreAdapter.js'
import { z } from 'zod'
import { adminEmail } from '../config/mail.js'

class RsvpController {
export default class RsvpController {
static PATHS = {
store: '/api/weeks/:weekId/rsvp',
}
Expand Down Expand Up @@ -84,5 +84,3 @@ type ErrorResponse = {
[key: string]: string,
}
}

export default RsvpController

0 comments on commit f802b23

Please sign in to comment.