-
Notifications
You must be signed in to change notification settings - Fork 241
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #620 from braintree/encrypted_shared_prefs_defensi…
…ve_guards Add Defensive Guards to Prevent Crashes Related to Jetpack Security Crypto
- Loading branch information
Showing
23 changed files
with
932 additions
and
342 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 8 additions & 0 deletions
8
BraintreeCore/src/main/java/com/braintreepayments/api/ConfigurationLoaderCallback.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
package com.braintreepayments.api; | ||
|
||
import androidx.annotation.Nullable; | ||
|
||
interface ConfigurationLoaderCallback { | ||
|
||
void onResult(@Nullable ConfigurationLoaderResult result, @Nullable Exception error); | ||
} |
33 changes: 33 additions & 0 deletions
33
BraintreeCore/src/main/java/com/braintreepayments/api/ConfigurationLoaderResult.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
package com.braintreepayments.api; | ||
|
||
import androidx.annotation.NonNull; | ||
import androidx.annotation.Nullable; | ||
|
||
class ConfigurationLoaderResult { | ||
|
||
private final Configuration configuration; | ||
private final Exception loadFromCacheError; | ||
private final Exception saveToCacheError; | ||
|
||
ConfigurationLoaderResult(@NonNull Configuration configuration) { | ||
this(configuration, null, null); | ||
} | ||
|
||
ConfigurationLoaderResult(@NonNull Configuration configuration, @Nullable Exception loadFromCacheError, @Nullable Exception saveToCacheError) { | ||
this.configuration = configuration; | ||
this.loadFromCacheError = loadFromCacheError; | ||
this.saveToCacheError = saveToCacheError; | ||
} | ||
|
||
public Configuration getConfiguration() { | ||
return configuration; | ||
} | ||
|
||
public Exception getLoadFromCacheError() { | ||
return loadFromCacheError; | ||
} | ||
|
||
public Exception getSaveToCacheError() { | ||
return saveToCacheError; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.