Skip to content

Commit

Permalink
solving preview user validations
Browse files Browse the repository at this point in the history
  • Loading branch information
RidhamShah committed Mar 4, 2024
1 parent 80ac904 commit fd68208
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
import { IsNotEmpty, IsDefined, ValidateNested, IsOptional, IsString, IsArray } from 'class-validator';
import { ValidateNested, IsOptional, IsString, IsArray } from 'class-validator';
import { Type } from 'class-transformer';
import { Experiment } from '../../../../src/api/models/Experiment';
import { ExperimentCondition } from '../../../../src/api/models/ExperimentCondition';

class ExplicitIndividualAssignment {
@IsNotEmpty()
@IsDefined()
@IsOptional()
@IsString()
public id: string;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -573,7 +573,7 @@ export class ExperimentAssignmentService {
// Create new filtered experiment
const alreadyAssignedExperiment = experimentPools.map((pool) => {
return pool.filter((experiment) => {
const individualEnrollment = individualEnrollments.find((enrollment) => {
const individualEnrollment = mergedIndividualAssignment.find((enrollment) => {
return enrollment.experiment.id === experiment.id;
});
const groupEnrollment = groupEnrollments.find((enrollment) => {
Expand Down

0 comments on commit fd68208

Please sign in to comment.