File tree Expand file tree Collapse file tree 1 file changed +1
-7
lines changed
packages/shared/sdk-server-edge/src/api Expand file tree Collapse file tree 1 file changed +1
-7
lines changed Original file line number Diff line number Diff line change @@ -38,9 +38,6 @@ export class EdgeFeatureStore implements LDFeatureStore {
3838
3939 try {
4040 const storePayload = await this . _getStorePayload ( ) ;
41- if ( ! storePayload ) {
42- throw new Error ( `Error retrieving valid store payload` ) ;
43- }
4441
4542 switch ( namespace ) {
4643 case 'features' :
@@ -64,9 +61,6 @@ export class EdgeFeatureStore implements LDFeatureStore {
6461 this . _logger . debug ( `Requesting all from ${ this . _rootKey } .${ kindKey } ` ) ;
6562 try {
6663 const storePayload = await this . _getStorePayload ( ) ;
67- if ( ! storePayload ) {
68- throw new Error ( `${ this . _rootKey } .${ kindKey } is not found in KV.` ) ;
69- }
7064
7165 switch ( namespace ) {
7266 case 'features' :
@@ -88,7 +82,7 @@ export class EdgeFeatureStore implements LDFeatureStore {
8882 * This method is used to retrieve the environment payload from the edge
8983 * provider. If a cache is provided, it will serve from that.
9084 */
91- private async _getStorePayload ( ) : Promise < ReturnType < typeof deserializePoll > > {
85+ private async _getStorePayload ( ) : Promise < Exclude < ReturnType < typeof deserializePoll > , undefined > > {
9286 let payload = this . _cache ?. get ( this . _rootKey ) ;
9387 if ( payload !== undefined ) {
9488 return payload ;
You can’t perform that action at this time.
0 commit comments