Total Complexity | 1 |
Complexity/F | 1 |
Lines of Code | 18 |
Function Count | 1 |
Duplicated Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | import {Injectable} from '@nestjs/common'; |
||
2 | import {InjectRepository} from '@nestjs/typeorm'; |
||
3 | import {Repository} from 'typeorm'; |
||
4 | import {IAddressRepository} from 'src/Domain/Customer/Repository/IAddressRepository'; |
||
5 | import {Address} from 'src/Domain/Customer/Address.entity'; |
||
6 | |||
7 | @Injectable() |
||
8 | export class AddressRepository implements IAddressRepository { |
||
9 | constructor( |
||
10 | @InjectRepository(Address) |
||
11 | private readonly repository: Repository<Address> |
||
12 | ) {} |
||
13 | |||
14 | public save(address: Address): Promise<Address> { |
||
15 | return this.repository.save(address); |
||
16 | } |
||
17 | } |
||
18 |