@@ -4,7 +4,7 @@ version '3.2.7'
44buildscript {
55 repositories {
66 google()
7- jcenter ()
7+ mavenCentral ()
88 }
99
1010 dependencies {
@@ -15,7 +15,7 @@ buildscript {
1515rootProject. allprojects {
1616 repositories {
1717 google()
18- jcenter ()
18+ mavenCentral ()
1919 }
2020}
2121
@@ -36,41 +36,3 @@ android {
3636dependencies {
3737 api ' com.onesignal:OneSignal:4.6.3'
3838}
39-
40- // Adds required manifestPlaceholders keys to allow mainifest merge gradle step to complete
41- // The OneSignal app id should be set in your JS code.
42- // Google project number / FCM Sender ID will be pulled in from the OneSignal dashbaord
43- class DefaultManifestPlaceHolders {
44- static final MANIFEST_PLACEHOLDERS_DEFAULTS = [
45- onesignal_app_id : ' ${onesignal_app_id}' ,
46- onesignal_google_project_number : ' ${onesignal_google_project_number}'
47- ]
48-
49- static void addManifestToAppProject (Project proj ) {
50- def androidApp = proj. android
51- MANIFEST_PLACEHOLDERS_DEFAULTS . each { defKey , defValue ->
52- if (! androidApp. defaultConfig. manifestPlaceholders. containsKey(defKey)) {
53- androidApp. defaultConfig. manifestPlaceholders[defKey] = defValue
54-
55- androidApp. buildTypes. each { buildType ->
56- if (! buildType. manifestPlaceholders. containsKey(defKey))
57- buildType. manifestPlaceholders[defKey] = defValue
58- }
59- }
60- }
61- }
62- }
63-
64- rootProject. childProjects. each { projName, proj ->
65- if (projName != ' app' && projName != ' onesignal_flutter' )
66- return
67-
68- if (proj. hasProperty(' android' )) {
69- DefaultManifestPlaceHolders . addManifestToAppProject(proj)
70- return
71- }
72-
73- proj. afterEvaluate {
74- DefaultManifestPlaceHolders . addManifestToAppProject(proj)
75- }
76- }
0 commit comments