website refactor
This commit is contained in:
@@ -6,15 +6,15 @@
|
||||
* basic invariants around identity and core properties.
|
||||
*/
|
||||
|
||||
import type { Entity } from '@core/shared/domain';
|
||||
import { MediaReference } from '@core/domain/media/MediaReference';
|
||||
import type { Entity } from '@core/shared/domain/Entity';
|
||||
import { RacingDomainValidationError } from '../errors/RacingDomainError';
|
||||
import { TeamCreatedAt } from '../value-objects/TeamCreatedAt';
|
||||
import { TeamDescription } from '../value-objects/TeamDescription';
|
||||
import { TeamName } from '../value-objects/TeamName';
|
||||
import { TeamTag } from '../value-objects/TeamTag';
|
||||
import { TeamDescription } from '../value-objects/TeamDescription';
|
||||
import { DriverId } from './DriverId';
|
||||
import { LeagueId } from './LeagueId';
|
||||
import { TeamCreatedAt } from '../value-objects/TeamCreatedAt';
|
||||
import { MediaReference } from '@core/domain/media/MediaReference';
|
||||
|
||||
export class Team implements Entity<string> {
|
||||
readonly id: string;
|
||||
@@ -159,4 +159,10 @@ export class Team implements Entity<string> {
|
||||
});
|
||||
}
|
||||
|
||||
equals(other: Entity<string>): boolean {
|
||||
if (!(other instanceof Team)) {
|
||||
return false;
|
||||
}
|
||||
return this.id === other.id;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user