MCPcopy Create free account
hub / github.com/dailydotdev/apps / enrichBootWithFeatures

Function enrichBootWithFeatures

packages/shared/src/lib/boot.ts:136–149  ·  view source on GitHub ↗
(boot: Boot)

Source from the content-addressed store, hash-verified

134};
135
136const enrichBootWithFeatures = async (boot: Boot): Promise<Boot> => {
137 if (!boot.exp || !process.env.NEXT_PUBLIC_EXPERIMENTATION_KEY) {
138 return boot;
139 }
140
141 const features = await decrypt(
142 boot.exp.f,
143 process.env.NEXT_PUBLIC_EXPERIMENTATION_KEY,
144 'AES-CBC',
145 128,
146 );
147
148 return { ...boot, exp: { ...boot.exp, features: JSON.parse(features) } };
149};
150
151interface GetBootDataParams {
152 app: string;

Callers 1

getBootDataFunction · 0.85

Calls 1

decryptFunction · 0.90

Tested by

no test coverage detected