@firebase/database
Advanced tools
Comparing version 0.1.7 to 0.1.8-canary.81d6b1e
@@ -53,3 +53,4 @@ "use strict"; | ||
// Catch common error of uninitialized namespace value. | ||
if (!namespace || namespace == 'undefined') { | ||
if ((!namespace || namespace == 'undefined') && | ||
parsedUrl.domain !== 'localhost') { | ||
util_1.fatal('Cannot parse Firebase url. Please use https://<YOUR FIREBASE>.firebaseio.com'); | ||
@@ -91,2 +92,11 @@ } | ||
pathString = decodePath(dataURL.substring(slashInd)); | ||
// If we have a port, use scheme for determining if it's secure. | ||
colonInd = host.indexOf(':'); | ||
if (colonInd >= 0) { | ||
secure = scheme === 'https' || scheme === 'wss'; | ||
port = parseInt(host.substring(colonInd + 1), 10); | ||
} | ||
else { | ||
colonInd = dataURL.length; | ||
} | ||
var parts = host.split('.'); | ||
@@ -101,7 +111,4 @@ if (parts.length === 3) { | ||
} | ||
// If we have a port, use scheme for determining if it's secure. | ||
colonInd = host.indexOf(':'); | ||
if (colonInd >= 0) { | ||
secure = scheme === 'https' || scheme === 'wss'; | ||
port = parseInt(host.substring(colonInd + 1), 10); | ||
else if (parts[0].slice(0, colonInd).toLowerCase() === 'localhost') { | ||
domain = 'localhost'; | ||
} | ||
@@ -108,0 +115,0 @@ } |
@@ -305,3 +305,4 @@ "use strict"; | ||
parsedUrl.repoInfo.host.length === 0 || | ||
!exports.isValidKey(parsedUrl.repoInfo.namespace) || | ||
(!exports.isValidKey(parsedUrl.repoInfo.namespace) && | ||
parsedUrl.repoInfo.host.split(':')[0] !== 'localhost') || | ||
(pathString.length !== 0 && !exports.isValidRootPathString(pathString))) { | ||
@@ -308,0 +309,0 @@ throw new Error(util_3.errorPrefix(fnName, argumentNumber, false) + |
@@ -51,3 +51,4 @@ /** | ||
// Catch common error of uninitialized namespace value. | ||
if (!namespace || namespace == 'undefined') { | ||
if ((!namespace || namespace == 'undefined') && | ||
parsedUrl.domain !== 'localhost') { | ||
fatal('Cannot parse Firebase url. Please use https://<YOUR FIREBASE>.firebaseio.com'); | ||
@@ -89,2 +90,11 @@ } | ||
pathString = decodePath(dataURL.substring(slashInd)); | ||
// If we have a port, use scheme for determining if it's secure. | ||
colonInd = host.indexOf(':'); | ||
if (colonInd >= 0) { | ||
secure = scheme === 'https' || scheme === 'wss'; | ||
port = parseInt(host.substring(colonInd + 1), 10); | ||
} | ||
else { | ||
colonInd = dataURL.length; | ||
} | ||
var parts = host.split('.'); | ||
@@ -99,7 +109,4 @@ if (parts.length === 3) { | ||
} | ||
// If we have a port, use scheme for determining if it's secure. | ||
colonInd = host.indexOf(':'); | ||
if (colonInd >= 0) { | ||
secure = scheme === 'https' || scheme === 'wss'; | ||
port = parseInt(host.substring(colonInd + 1), 10); | ||
else if (parts[0].slice(0, colonInd).toLowerCase() === 'localhost') { | ||
domain = 'localhost'; | ||
} | ||
@@ -106,0 +113,0 @@ } |
@@ -303,3 +303,4 @@ /** | ||
parsedUrl.repoInfo.host.length === 0 || | ||
!isValidKey(parsedUrl.repoInfo.namespace) || | ||
(!isValidKey(parsedUrl.repoInfo.namespace) && | ||
parsedUrl.repoInfo.host.split(':')[0] !== 'localhost') || | ||
(pathString.length !== 0 && !isValidRootPathString(pathString))) { | ||
@@ -306,0 +307,0 @@ throw new Error(errorPrefixFxn(fnName, argumentNumber, false) + |
{ | ||
"name": "@firebase/database", | ||
"version": "0.1.7", | ||
"version": "0.1.8-canary.81d6b1e", | ||
"description": "", | ||
@@ -13,3 +13,3 @@ "author": "Firebase <firebase-support@google.com> (https://firebase.google.com/)", | ||
"test:browser": "karma start --single-run", | ||
"test:node": "nyc --reporter lcovonly -- mocha 'test/{,!(browser)/**/}*.test.ts' --compilers ts:ts-node/register -r src/nodePatches.ts --retries 5 --timeout 5000 --exit", | ||
"test:node": "TS_NODE_CACHE=NO nyc --reporter lcovonly -- mocha 'test/{,!(browser)/**/}*.test.ts' --compilers ts:ts-node/register/type-check -r src/nodePatches.ts --retries 5 --timeout 5000 --exit", | ||
"prepare": "gulp build" | ||
@@ -19,8 +19,8 @@ }, | ||
"peerDependencies": { | ||
"@firebase/app": "^0.1.0", | ||
"@firebase/app-types": "^0.1.0" | ||
"@firebase/app": "0.1.7-canary.81d6b1e", | ||
"@firebase/app-types": "0.1.1-canary.81d6b1e" | ||
}, | ||
"dependencies": { | ||
"@firebase/database-types": "0.1.1", | ||
"@firebase/util": "0.1.6", | ||
"@firebase/database-types": "0.1.1-canary.81d6b1e", | ||
"@firebase/util": "0.1.7-canary.81d6b1e", | ||
"faye-websocket": "0.11.1" | ||
@@ -49,3 +49,3 @@ }, | ||
"ts-loader": "^3.1.0", | ||
"ts-node": "^3.3.0", | ||
"ts-node": "^4.1.0", | ||
"typescript": "^2.4.2", | ||
@@ -52,0 +52,0 @@ "webpack": "^3.8.1" |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
3775494
45760
+ Added@firebase/app@0.1.7-canary.81d6b1e(transitive)
+ Added@firebase/app-types@0.1.1-canary.81d6b1e(transitive)
+ Added@firebase/database-types@0.1.1-canary.81d6b1e(transitive)
+ Added@firebase/util@0.1.7-canary.81d6b1e(transitive)
- Removed@firebase/app@0.1.10(transitive)
- Removed@firebase/app-types@0.1.2(transitive)
- Removed@firebase/database-types@0.1.1(transitive)
- Removed@firebase/util@0.1.100.1.6(transitive)
- Removedtslib@1.14.1(transitive)