1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
|
/**
* Create an "unauthenticated" {@linkcode User} representation
*
* The property values below match the way that `AppStoreKit` will define the `user`
* when the session is not authenticated.
*/
export function makeUnauthenticatedUser(): User {
return {
accountIdentifier: undefined,
dsid: undefined,
firstName: undefined,
// Note: this property is `true` for the native apps but `false` makes
// more sense in the context of the "web" client
isFitnessAppInstallationAllowed: false,
isManagedAppleID: false,
isOnDevicePersonalizationEnabled: false,
isUnderThirteen: false,
katanaId: undefined,
lastName: undefined,
treatmentGroupIdOverride: undefined,
userAgeIfAvailable: undefined,
onDevicePersonalizationDataContainerForAppIds(appIds) {
return {
personalizationData: {},
metricsData: {},
};
},
};
}
|