Skip to content

Commit 73cc2dd

Browse files
authored
[PR-22929] Update Facebook SDK and dependencies (#13)
1 parent 6a562b9 commit 73cc2dd

File tree

3 files changed

+16
-15
lines changed

3 files changed

+16
-15
lines changed

build.gradle

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@
22

33
buildscript {
44
repositories {
5-
jcenter()
5+
mavenCentral()
66
google()
77
}
88
dependencies {
9-
classpath 'com.android.tools.build:gradle:3.4.3'
10-
classpath 'de.mobilej.unmock:UnMockPlugin:0.6.4'
9+
classpath 'com.android.tools.build:gradle:3.6.4'
10+
classpath 'com.github.bjoernq:unmockplugin:0.7.6'
1111
classpath 'com.github.dcendents:android-maven-gradle-plugin:2.0'
1212

1313
// NOTE: Do not place your application dependencies here; they belong
@@ -17,7 +17,7 @@ buildscript {
1717

1818
allprojects {
1919
repositories {
20-
jcenter()
20+
mavenCentral()
2121
google()
2222
maven { url 'https://jitpack.io' }
2323
}

sdk/build.gradle

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,13 @@ apply plugin: 'com.github.dcendents.android-maven'
55
group='com.github.talkable'
66

77
android {
8-
compileSdkVersion 31
8+
compileSdkVersion 33
99

1010
defaultConfig {
1111
minSdkVersion 16
12-
targetSdkVersion 31
13-
versionCode 41
14-
versionName "0.5.12"
12+
targetSdkVersion 33
13+
versionCode 42
14+
versionName "0.5.13"
1515
testInstrumentationRunner 'androidx.test.runner.AndroidJUnitRunner'
1616
}
1717
buildTypes {
@@ -37,7 +37,7 @@ repositories {
3737
dependencies {
3838
implementation fileTree(include: ['*.jar'], dir: 'libs')
3939

40-
testImplementation 'junit:junit:4.12'
40+
testImplementation 'junit:junit:4.13.2'
4141

4242
testImplementation 'org.mockito:mockito-core:1.10.19'
4343
testImplementation('org.powermock:powermock-api-mockito:1.6.6') {
@@ -49,14 +49,14 @@ dependencies {
4949
exclude module: 'objenesis'
5050
}
5151

52-
androidTestImplementation 'androidx.annotation:annotation:1.0.0'
53-
androidTestImplementation 'androidx.test.ext:junit:1.1.1'
54-
androidTestImplementation 'androidx.test:rules:1.1.1'
52+
androidTestImplementation 'androidx.annotation:annotation:1.8.2'
53+
androidTestImplementation 'androidx.test.ext:junit:1.2.1'
54+
androidTestImplementation 'androidx.test:rules:1.6.1'
5555

56-
implementation 'androidx.annotation:annotation:1.0.0'
56+
implementation 'androidx.annotation:annotation:1.8.2'
5757
implementation 'com.squareup.okhttp3:okhttp:3.2.0' // update to a new version when https://github.com/square/okhttp/issues/3928 will be fixed
5858
implementation 'com.squareup.okhttp3:logging-interceptor:3.2.0'
59-
implementation 'com.facebook.android:facebook-android-sdk:14.1.1'
59+
implementation 'com.facebook.android:facebook-android-sdk:15.2.0'
6060
implementation 'com.google.code.gson:gson:2.8.+'
6161
implementation 'androidx.legacy:legacy-support-v4:1.0.0'
6262
}

sdk/src/main/java/com/talkable/sdk/utils/NativeFeatures.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
import android.telephony.TelephonyManager;
99

1010
import com.facebook.FacebookSdk;
11+
import com.facebook.internal.FacebookSignatureValidator;
1112
import com.facebook.messenger.MessengerUtils;
1213
import com.google.gson.JsonObject;
1314
import com.talkable.sdk.BuildConfig;
@@ -54,7 +55,7 @@ public static void initialize(Context context) {
5455
isSmsAvailable = true;
5556
}
5657

57-
isMessengerInstalled = MessengerUtils.hasMessengerInstalled(context);
58+
isMessengerInstalled = FacebookSignatureValidator.validateSignature(context, MessengerUtils.PACKAGE_NAME);
5859
isWhatsAppAvailable = isPackageInstalled("com.whatsapp", context);
5960

6061
Intent sendNativeMailIntent = new Intent(Intent.ACTION_SENDTO);

0 commit comments

Comments
 (0)