Skip to content

Commit 0827129

Browse files
committed
fix(appstore): fix invalid signature of GetSubscriptionRenewalDataStatus
1 parent 59b09be commit 0827129

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

appstore/api/store.go

+4-4
Original file line numberDiff line numberDiff line change
@@ -301,7 +301,7 @@ func (a *StoreClient) ExtendSubscriptionRenewalDateForAll(ctx context.Context, b
301301
}
302302

303303
// GetSubscriptionRenewalDataStatus https://developer.apple.com/documentation/appstoreserverapi/get_status_of_subscription_renewal_date_extensions
304-
func (a *StoreClient) GetSubscriptionRenewalDataStatus(ctx context.Context, productId, requestIdentifier string) (rsp *MassExtendRenewalDateStatusResponse, err error) {
304+
func (a *StoreClient) GetSubscriptionRenewalDataStatus(ctx context.Context, productId, requestIdentifier string) (statusCode int, rsp *MassExtendRenewalDateStatusResponse, err error) {
305305
URL := HostProduction + PathGetStatusOfSubscriptionRenewalDate
306306
if a.Token.Sandbox {
307307
URL = HostSandBox + PathGetStatusOfSubscriptionRenewalDate
@@ -311,15 +311,15 @@ func (a *StoreClient) GetSubscriptionRenewalDataStatus(ctx context.Context, prod
311311

312312
statusCode, body, err := a.Do(ctx, http.MethodGet, URL, nil)
313313
if statusCode != http.StatusOK {
314-
return nil, fmt.Errorf("appstore api: %v return status code %v", URL, statusCode)
314+
return statusCode, nil, fmt.Errorf("appstore api: %v return status code %v", URL, statusCode)
315315
}
316316

317317
err = json.Unmarshal(body, &rsp)
318318
if err != nil {
319-
return nil, err
319+
return statusCode, nil, err
320320
}
321321

322-
return rsp, nil
322+
return statusCode, rsp, nil
323323
}
324324

325325
// GetNotificationHistory https://developer.apple.com/documentation/appstoreserverapi/get_notification_history

0 commit comments

Comments
 (0)