File tree Expand file tree Collapse file tree 2 files changed +7
-3
lines changed
packages/transporter/src/concerns Expand file tree Collapse file tree 2 files changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -26,14 +26,14 @@ export const retryDecision = <TResponse>(
2626 }
2727
2828 if ( isSuccess ( response ) ) {
29- return outcomes . onSucess ( response ) ;
29+ return outcomes . onSuccess ( response ) ;
3030 }
3131
3232 return outcomes . onFail ( response ) ;
3333} ;
3434
3535export type Outcomes < TResponse > = {
3636 readonly onFail : ( response : Response ) => Readonly < Promise < never > > ;
37- readonly onSucess : ( response : Response ) => Readonly < Promise < TResponse > > ;
37+ readonly onSuccess : ( response : Response ) => Readonly < Promise < TResponse > > ;
3838 readonly onRetry : ( response : Response ) => Readonly < Promise < TResponse > > ;
3939} ;
Original file line number Diff line number Diff line change @@ -94,7 +94,11 @@ export function retryableRequest<TResponse>(
9494 } ;
9595
9696 const decisions : Outcomes < TResponse > = {
97- onSucess : response => deserializeSuccess ( response ) ,
97+ /**
98+ * @deprecated this property is deprecated in favor of `onSuccess`
99+ */
100+ onSucess : response => onSuccess ( response ) ,
101+ onSuccess : response => deserializeSuccess ( response ) ,
98102 onRetry ( response ) {
99103 const stackFrame = pushToStackTrace ( response ) ;
100104
You can’t perform that action at this time.
0 commit comments