Skip to content

Commit

Permalink
Issue in RN when app moves to BG loses connectivity
Browse files Browse the repository at this point in the history
  • Loading branch information
OsamaRabie committed Dec 21, 2023
1 parent 994a22d commit a7c23d0
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion goSellSDK.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Pod::Spec.new do |goSellSDK|
goSellSDK.name = 'goSellSDK'
goSellSDK.summary = 'goSell SDK for iOS'
goSellSDK.requires_arc = true
goSellSDK.version = '2.3.31'
goSellSDK.version = '2.3.32'
goSellSDK.license = { :type => 'MIT', :file => 'LICENSE' }
goSellSDK.author = { 'Tap Payments' => '[email protected]' }
goSellSDK.homepage = 'https://github.com/Tap-Payments/goSellSDK-iOS'
Expand Down
8 changes: 6 additions & 2 deletions goSellSDK/Core/UI/Internal/Data/ErrorDataManager.swift
Original file line number Diff line number Diff line change
Expand Up @@ -178,8 +178,12 @@ internal class ErrorDataManager {
#endif

if action.contains(.retry) {

ErrorActionExecutor.showAlert(for: error, with: alertTitle, message: alertMessage, retryAction: retryAction, report: report, completion: localCompletion)
let state = UIApplication.shared.applicationState
if (state == .background || state == .inactive) && error.type == .network {
retryAction?()
}else {
ErrorActionExecutor.showAlert(for: error, with: alertTitle, message: alertMessage, retryAction: retryAction, report: report, completion: localCompletion)
}
}
else {

Expand Down

0 comments on commit a7c23d0

Please sign in to comment.