File tree Expand file tree Collapse file tree 3 files changed +6
-5
lines changed Expand file tree Collapse file tree 3 files changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -21,6 +21,7 @@ import { Query } from "./database/api/Query";
21
21
import { Reference } from "./database/api/Reference" ;
22
22
import { enableLogging } from "./database/core/util/util" ;
23
23
import { RepoManager } from "./database/core/RepoManager" ;
24
+ import * as INTERNAL from './database/api/internal' ;
24
25
25
26
export function registerDatabase ( instance ) {
26
27
// Register the Database Service with the 'firebase' namespace.
@@ -33,6 +34,7 @@ export function registerDatabase(instance) {
33
34
Query,
34
35
Database,
35
36
enableLogging,
37
+ INTERNAL ,
36
38
ServerValue : Database . ServerValue ,
37
39
}
38
40
) ;
Original file line number Diff line number Diff line change @@ -22,12 +22,11 @@ export function nodeFromJSON(json, priority?) {
22
22
return ChildrenNode . EMPTY_NODE ;
23
23
}
24
24
25
- var priority = null ;
25
+ priority = priority || null ;
26
26
if ( typeof json === 'object' && '.priority' in json ) {
27
27
priority = json [ '.priority' ] ;
28
- } else if ( typeof priority !== 'undefined' ) {
29
- priority = priority ;
30
28
}
29
+
31
30
assert (
32
31
priority === null ||
33
32
typeof priority === 'string' ||
@@ -79,7 +78,7 @@ export function nodeFromJSON(json, priority?) {
79
78
} else {
80
79
var node = ChildrenNode . EMPTY_NODE ;
81
80
var jsonObj = /** @type {!Object } */ ( json ) ;
82
- forEach ( jsonObj , function ( childData , key ) {
81
+ forEach ( jsonObj , function ( key , childData ) {
83
82
if ( contains ( jsonObj , key ) ) {
84
83
if ( key . substring ( 0 , 1 ) !== '.' ) { // ignore metadata nodes.
85
84
var childNode = nodeFromJSON ( childData ) ;
Original file line number Diff line number Diff line change @@ -185,7 +185,7 @@ export class Sha1 extends Hash {
185
185
return ;
186
186
}
187
187
188
- if ( opt_length === ' undefined' ) {
188
+ if ( opt_length === undefined ) {
189
189
opt_length = bytes . length ;
190
190
}
191
191
You can’t perform that action at this time.
0 commit comments