Skip to content
This repository was archived by the owner on Apr 4, 2023. It is now read-only.

Commit 5333b95

Browse files
fix: use string concatenation instead of format #1260
1 parent 2929b78 commit 5333b95

File tree

7 files changed

+45
-31
lines changed

7 files changed

+45
-31
lines changed

demo-ng/package.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,10 @@
66
"nativescript": {
77
"id": "org.nativescript.firebasedemo.firestore",
88
"tns-android": {
9-
"version": "5.1.0"
9+
"version": "5.2.0"
1010
},
1111
"tns-ios": {
12-
"version": "5.1.0"
12+
"version": "5.2.0"
1313
}
1414
},
1515
"dependencies": {
@@ -25,11 +25,11 @@
2525
"nativescript-angular": "^6.1.0",
2626
"nativescript-camera": "~4.1.1",
2727
"nativescript-imagepicker": "~6.0.5",
28-
"nativescript-plugin-firebase": "file:../publish/package/nativescript-plugin-firebase-8.3.1.tgz",
28+
"nativescript-plugin-firebase": "file:../publish/package/nativescript-plugin-firebase-8.3.2.tgz",
2929
"nativescript-theme-core": "~1.0.4",
3030
"reflect-metadata": "~0.1.10",
3131
"rxjs": "~6.0.0 || >=6.1.0",
32-
"tns-core-modules": "~5.1.0",
32+
"tns-core-modules": "~5.2.0",
3333
"zone.js": "~0.8.26"
3434
},
3535
"devDependencies": {

demo-push/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
}
1010
},
1111
"dependencies": {
12-
"nativescript-plugin-firebase": "file:../publish/package/nativescript-plugin-firebase-8.3.1.tgz",
12+
"nativescript-plugin-firebase": "file:../publish/package/nativescript-plugin-firebase-8.3.2.tgz",
1313
"nativescript-theme-core": "^1.0.4",
1414
"nativescript-unit-test-runner": "^0.3.4",
1515
"tns-core-modules": "~4.2.0"

demo-vue/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
}
1515
},
1616
"dependencies": {
17-
"nativescript-plugin-firebase": "file:../publish/package/nativescript-plugin-firebase-8.3.1.tgz",
17+
"nativescript-plugin-firebase": "file:../publish/package/nativescript-plugin-firebase-8.3.2.tgz",
1818
"nativescript-theme-core": "^1.0.4",
1919
"nativescript-vue": "^2.0.0",
2020
"tns-core-modules": "^5.0.2"

demo/package.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,18 +2,18 @@
22
"nativescript": {
33
"id": "org.nativescript.firebasedemo",
44
"tns-ios": {
5-
"version": "5.2.0"
5+
"version": "5.3.1"
66
},
77
"tns-android": {
8-
"version": "5.2.0"
8+
"version": "5.3.1"
99
}
1010
},
1111
"dependencies": {
1212
"firebase-functions": "^2.0.5",
13-
"nativescript-plugin-firebase": "file:../publish/package/nativescript-plugin-firebase-8.3.1.tgz",
13+
"nativescript-plugin-firebase": "file:../publish/package/nativescript-plugin-firebase-8.3.2.tgz",
1414
"nativescript-theme-core": "^1.0.4",
1515
"nativescript-unit-test-runner": "^0.3.4",
16-
"tns-core-modules": "~5.2.0"
16+
"tns-core-modules": "~5.3.0"
1717
},
1818
"devDependencies": {
1919
"@types/jasmine": "~2.8.0",
@@ -29,7 +29,7 @@
2929
"nativescript-css-loader": "~0.26.0",
3030
"nativescript-dev-typescript": "~0.7.1",
3131
"nativescript-dev-webpack": "^0.16.2",
32-
"tns-platform-declarations": "~5.2.0",
32+
"tns-platform-declarations": "~5.3.0",
3333
"tslint": "~5.4.3",
3434
"typescript": "~2.8.0"
3535
},

publish/scripts/installer.js

Lines changed: 16 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1099,17 +1099,24 @@ module.exports = function($logger, $projectData) {
10991099
appBuildGradleContent += \`
11001100
task copyMetadata {
11011101
doFirst {
1102-
android.applicationVariants.all { variant ->
1103-
def provider = variant.getMergeAssetsProvider()
1104-
if (variant.buildType.name == project.selectedBuildType) {
1105-
def task = provider.get();
1106-
for (File file : task.getOutputs().getFiles()) {
1107-
if (!file.getPath().contains("/incremental/")) {
1108-
project.ext.mergedAssetsOutputPath = file.getPath()
1102+
// before tns-android 5.2.0 its gradle version didn't have this method implemented, so pri
1103+
android.applicationVariants.all { variant ->
1104+
if (variant.buildType.name == project.selectedBuildType) {
1105+
def task
1106+
if (variant.metaClass.respondsTo(variant, "getMergeAssetsProvider")) {
1107+
def provider = variant.getMergeAssetsProvider()
1108+
task = provider.get();
1109+
} else {
1110+
// fallback for older android gradle plugin versions
1111+
task = variant.getMergeAssets()
1112+
}
1113+
for (File file : task.getOutputs().getFiles()) {
1114+
if (!file.getPath().contains("/incremental/")) {
1115+
project.ext.mergedAssetsOutputPath = file.getPath()
1116+
}
1117+
}
11091118
}
1110-
}
11111119
}
1112-
}
11131120
}
11141121
doLast {
11151122
copy {

src/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "nativescript-plugin-firebase",
3-
"version": "8.3.1",
3+
"version": "8.3.2",
44
"description": "Fire. Base. Firebase!",
55
"main": "firebase",
66
"typings": "index.d.ts",

src/scripts/postinstall.js

Lines changed: 17 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2251,7 +2251,7 @@ function coerce(version) {
22512251
if (match == null)
22522252
return null;
22532253

2254-
return parse((match[1] || '0') + '.' + (match[2] || '0') + '.' + (match[3] || '0'));
2254+
return parse((match[1] || '0') + '.' + (match[2] || '0') + '.' + (match[3] || '0'));
22552255
}
22562256

22572257

@@ -5271,17 +5271,24 @@ module.exports = function($logger, $projectData) {
52715271
appBuildGradleContent += \`
52725272
task copyMetadata {
52735273
doFirst {
5274-
android.applicationVariants.all { variant ->
5275-
def provider = variant.getMergeAssetsProvider()
5276-
if (variant.buildType.name == project.selectedBuildType) {
5277-
def task = provider.get();
5278-
for (File file : task.getOutputs().getFiles()) {
5279-
if (!file.getPath().contains("/incremental/")) {
5280-
project.ext.mergedAssetsOutputPath = file.getPath()
5274+
// before tns-android 5.2.0 its gradle version didn't have this method implemented, so pri
5275+
android.applicationVariants.all { variant ->
5276+
if (variant.buildType.name == project.selectedBuildType) {
5277+
def task
5278+
if (variant.metaClass.respondsTo(variant, "getMergeAssetsProvider")) {
5279+
def provider = variant.getMergeAssetsProvider()
5280+
task = provider.get();
5281+
} else {
5282+
// fallback for older android gradle plugin versions
5283+
task = variant.getMergeAssets()
5284+
}
5285+
for (File file : task.getOutputs().getFiles()) {
5286+
if (!file.getPath().contains("/incremental/")) {
5287+
project.ext.mergedAssetsOutputPath = file.getPath()
5288+
}
5289+
}
52815290
}
5282-
}
52835291
}
5284-
}
52855292
}
52865293
doLast {
52875294
copy {

0 commit comments

Comments
 (0)