From 6d2033abd27164a6cefbe73b88f5d0b22a35201c Mon Sep 17 00:00:00 2001 From: Moriz Wahl Date: Tue, 19 Apr 2022 08:36:38 +0200 Subject: [PATCH] no interface --- backend/src/graphql/model/Decay.ts | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) diff --git a/backend/src/graphql/model/Decay.ts b/backend/src/graphql/model/Decay.ts index 591294df5..46aef4263 100644 --- a/backend/src/graphql/model/Decay.ts +++ b/backend/src/graphql/model/Decay.ts @@ -1,18 +1,16 @@ import { ObjectType, Field, Int } from 'type-graphql' import Decimal from 'decimal.js-light' -interface DecayInterface { - balance: Decimal - decay: Decimal - roundedDecay: Decimal - start: Date | null - end: Date | null - duration: number | null -} - @ObjectType() export class Decay { - constructor(data: DecayInterface) { + constructor(data: { + balance: Decimal + decay: Decimal + roundedDecay: Decimal + start: Date | null + end: Date | null + duration: number | null + }) { this.balance = data.balance this.decay = data.decay this.roundedDecay = data.roundedDecay