@@ -17,7 +17,7 @@ export class ResponseRunnerCard {
|
||||
* This is important to link scans to runners.
|
||||
*/
|
||||
@IsObject()
|
||||
runner: ResponseRunner;
|
||||
runner: ResponseRunner | null;
|
||||
|
||||
/**
|
||||
* The card's code.
|
||||
@@ -40,7 +40,8 @@ export class ResponseRunnerCard {
|
||||
*/
|
||||
public constructor(card: RunnerCard) {
|
||||
this.id = card.id;
|
||||
this.runner = card.runner.toResponse() || null;
|
||||
if (!card.runner) { this.runner = null }
|
||||
else { this.runner = card.runner.toResponse(); }
|
||||
this.code = card.code;
|
||||
this.enabled = card.enabled;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user