mirror of
				https://github.com/Mueller-Patrick/Betterzon.git
				synced 2025-10-31 00:35:48 +00:00 
			
		
		
		
	BETTERZON-100: Some more code reformatting
This commit is contained in:
		
							parent
							
								
									7ddf5ffe84
								
							
						
					
					
						commit
						ce21d1f527
					
				|  | @ -15,6 +15,7 @@ import {errorHandler} from './middleware/error.middleware'; | |||
| import {notFoundHandler} from './middleware/notFound.middleware'; | ||||
| import {usersRouter} from './models/users/users.router'; | ||||
| import {pricealarmsRouter} from './models/pricealarms/pricealarms.router'; | ||||
| 
 | ||||
| const cookieParser = require('cookie-parser'); | ||||
| 
 | ||||
| dotenv.config(); | ||||
|  |  | |||
|  | @ -1,5 +1,5 @@ | |||
| import HttpException from "../common/http-exception"; | ||||
| import { Request, Response, NextFunction } from "express"; | ||||
| import HttpException from '../common/http-exception'; | ||||
| import {Request, Response, NextFunction} from 'express'; | ||||
| 
 | ||||
| export const errorHandler = ( | ||||
|     error: HttpException, | ||||
|  | @ -9,7 +9,7 @@ export const errorHandler = ( | |||
| ) => { | ||||
|     const status = error.statusCode || 500; | ||||
|     const message = | ||||
|         error.message || "It's not you. It's us. We are having some problems."; | ||||
|         error.message || 'It\'s not you. It\'s us. We are having some problems.'; | ||||
| 
 | ||||
|     response.status(status).send(message); | ||||
| }; | ||||
|  |  | |||
|  | @ -1,4 +1,4 @@ | |||
| import { Request, Response, NextFunction } from "express"; | ||||
| import {Request, Response, NextFunction} from 'express'; | ||||
| 
 | ||||
| export const notFoundHandler = ( | ||||
|     request: Request, | ||||
|  | @ -6,7 +6,7 @@ export const notFoundHandler = ( | |||
|     next: NextFunction | ||||
| ) => { | ||||
| 
 | ||||
|     const message = "Resource not found"; | ||||
|     const message = 'Resource not found'; | ||||
| 
 | ||||
|     response.status(404).send(message); | ||||
| }; | ||||
|  |  | |||
|  | @ -1,32 +1,32 @@ | |||
| const webpack = require("webpack"); | ||||
| const path = require("path"); | ||||
| const nodeExternals = require("webpack-node-externals"); | ||||
| const webpack = require('webpack'); | ||||
| const path = require('path'); | ||||
| const nodeExternals = require('webpack-node-externals'); | ||||
| 
 | ||||
| module.exports = { | ||||
|     entry: ["webpack/hot/poll?100", "./src/index.ts"], | ||||
|     entry: ['webpack/hot/poll?100', './src/index.ts'], | ||||
|     watch: false, | ||||
|     target: "node", | ||||
|     target: 'node', | ||||
|     externals: [ | ||||
|         nodeExternals({ | ||||
|             whitelist: ["webpack/hot/poll?100"] | ||||
|             whitelist: ['webpack/hot/poll?100'] | ||||
|         }) | ||||
|     ], | ||||
|     module: { | ||||
|         rules: [ | ||||
|             { | ||||
|                 test: /.tsx?$/, | ||||
|                 use: "ts-loader", | ||||
|                 use: 'ts-loader', | ||||
|                 exclude: /node_modules/ | ||||
|             } | ||||
|         ] | ||||
|     }, | ||||
|     mode: "development", | ||||
|     mode: 'development', | ||||
|     resolve: { | ||||
|         extensions: [".tsx", ".ts", ".js"] | ||||
|         extensions: ['.tsx', '.ts', '.js'] | ||||
|     }, | ||||
|     plugins: [new webpack.HotModuleReplacementPlugin()], | ||||
|     output: { | ||||
|         path: path.join(__dirname, "dist"), | ||||
|         filename: "index.js" | ||||
|         path: path.join(__dirname, 'dist'), | ||||
|         filename: 'index.js' | ||||
|     } | ||||
| }; | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue
	
	Block a user