Skip to content

Commit

Permalink
chores: remove uneeded deps and configs
Browse files Browse the repository at this point in the history
  • Loading branch information
rubiin committed Oct 3, 2023
1 parent 7bdb322 commit 0d67663
Show file tree
Hide file tree
Showing 6 changed files with 10 additions and 17 deletions.
2 changes: 1 addition & 1 deletion .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,5 @@ trim_trailing_whitespace = true
quote_type = single

[Makefile]
indent_size = 8
indent_size = 4
indent_style = tab
6 changes: 1 addition & 5 deletions .lintstagedrc
Original file line number Diff line number Diff line change
@@ -1,9 +1,5 @@
{
"*.{ts,tsx}": [
"eslint_d '{src,test}/**/*.ts' --cache --fix",
"prettier --cache --write"
],
"*.{json,md,yaml,yml}": [
"prettier --cache --write"
"eslint --cache --fix"
]
}
5 changes: 1 addition & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@
"lint": "eslint --cache",
"lint:fix": "eslint --cache --fix",
"orm": "npx mikro-orm",
"prebuild": "rimraf dist",
"sample": "cd env; npx sample-env --env .env.dev",
"start": "nest start",
"start:dev": "nest start --watch",
Expand Down Expand Up @@ -98,7 +97,6 @@
"date-fns": "^2.30.0",
"date-fns-tz": "^2.0.0",
"eta": "^3.1.1",
"express-basic-auth": "^1.2.1",
"firebase-admin": "^11.11.0",
"handlebars": "^4.7.8",
"helmet": "^7.0.0",
Expand All @@ -123,7 +121,7 @@
"passport-magic-login": "^1.2.2",
"pino-http": "^8.5.0",
"pino-pretty": "^10.2.0",
"poolifier": "^2.7.4",
"poolifier": "^2.7.5",
"preview-email": "^3.0.19",
"prom-client": "^14.2.0",
"pug": "^3.0.2",
Expand Down Expand Up @@ -178,7 +176,6 @@
"cross-env": "^7.0.3",
"cz-conventional-changelog": "3.3.0",
"eslint": "^8.50.0",
"eslint_d": "^12.2.1",
"husky": "^8.0.3",
"jest": "29.7.0",
"lint-staged": "^14.0.1",
Expand Down
8 changes: 4 additions & 4 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/common/@types/types/common.types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@ export type Optional<T> = T | undefined;
export type Nullable<T> = T | null;

// This type represents a dto that contains a file or files
export type DtoWithFile<T, K = File> = T & {
export type RecordWithFile<T, K = File> = T & {
files: K
};
4 changes: 2 additions & 2 deletions src/modules/user/user.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import type { Observable } from "rxjs";
import { from, map, mergeMap, of, switchMap, throwError } from "rxjs";

import type {
DtoWithFile,
RecordWithFile,
PaginationResponse,
} from "@common/@types";
import {
Expand Down Expand Up @@ -99,7 +99,7 @@ export class UserService {
* @param dto - CreateWithFile<CreateUserDto>
* @returns The user object
*/
create(dto: DtoWithFile<CreateUserDto>): Observable<User> {
create(dto: RecordWithFile<CreateUserDto>): Observable<User> {
const { files, ...rest } = dto;
const user = this.userRepository.create(rest);

Expand Down

0 comments on commit 0d67663

Please sign in to comment.