mirror of
https://github.com/fluxerapp/fluxer
synced 2026-10-17 21:15:32 +09:00
feat(profile): ship profile timezone to everyone (#3034)
This commit is contained in:
1 parent
b30ea361d3
commit
d433a039b5
28 files changed
+71
-971
No files matched your search
@@ -5,10 +5,6 @@ import {
|
||||
DomainMigrationAssignmentResponse,
|
||||
INERT_DOMAIN_MIGRATION_ASSIGNMENT,
|
||||
} from '@fluxer/schema/src/domains/admin/DomainMigrationSchemas';
|
||||
import {
|
||||
INERT_PROFILE_TIMEZONE_ASSIGNMENT,
|
||||
ProfileTimezoneAssignmentResponse,
|
||||
} from '@fluxer/schema/src/domains/admin/ProfileTimezoneSchemas';
|
||||
import {z} from 'zod';
|
||||
|
||||
export const EXPERIMENT_MIN_POLL_INTERVAL_SECONDS = 60;
|
||||
@@ -48,7 +44,6 @@ export type ExperimentDeliveryConfigResponse = z.infer<typeof ExperimentDelivery
|
||||
const ExperimentAssignmentsSchema = z.object({
|
||||
domain_migration: DomainMigrationAssignmentResponse.optional(),
|
||||
altcha_captcha: AltchaCaptchaAssignmentResponse.optional(),
|
||||
profile_timezone: ProfileTimezoneAssignmentResponse.optional(),
|
||||
});
|
||||
|
||||
export const ExperimentAssignmentsResponse = z.object({
|
||||
@@ -70,9 +65,3 @@ export function readDomainMigrationAssignment(
|
||||
): DomainMigrationAssignmentResponse {
|
||||
return response.assignments.domain_migration ?? INERT_DOMAIN_MIGRATION_ASSIGNMENT;
|
||||
}
|
||||
|
||||
export function readProfileTimezoneAssignment(
|
||||
response: ExperimentAssignmentsResponse,
|
||||
): ProfileTimezoneAssignmentResponse {
|
||||
return response.assignments.profile_timezone ?? INERT_PROFILE_TIMEZONE_ASSIGNMENT;
|
||||
}
|
||||
Reference in new issue
Block a user