Skip to content

Commit 84ef759

Browse files
authored
Fix bug where direct signups don't use parent startTime (#1243)
1 parent 750a279 commit 84ef759

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

server/src/features/direct-signup/directSignupService.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,10 +100,14 @@ export const storeDirectSignup = async (
100100
};
101101
}
102102

103+
const parentStartTime = config
104+
.event()
105+
.startTimesByParentIds.get(programItem.parentId);
106+
103107
const newDirectSignup: SignupRepositoryAddSignup = {
104108
...signupRequest,
105109
username,
106-
signedToStartTime: programItem.startTime,
110+
signedToStartTime: parentStartTime ?? programItem.startTime,
107111
};
108112

109113
const signupResult = await saveDirectSignup(newDirectSignup);

0 commit comments

Comments
 (0)