@@ -22,7 +22,7 @@ function createCounter(ref, num_shards) {
2222// [END create_counter]
2323
2424// [START increment_counter]
25- function incrementCounter ( db , ref , num_shards ) {
25+ function incrementCounter ( ref , num_shards ) {
2626 // Select a shard of the counter at random
2727 const shard_id = Math . floor ( Math . random ( ) * num_shards ) . toString ( ) ;
2828 const shard_ref = ref . collection ( 'shards' ) . doc ( shard_id ) ;
@@ -67,15 +67,15 @@ describe("firestore-solution-counters", () => {
6767 // Create a counter, then increment it
6868 const ref = db . collection ( 'counters' ) . doc ( ) ;
6969 return createCounter ( ref , 10 ) . then ( ( ) => {
70- return incrementCounter ( db , ref , 10 ) ;
70+ return incrementCounter ( ref , 10 ) ;
7171 } ) ;
7272 } ) ;
7373
7474 it ( "should get the count of a counter" , ( ) => {
7575 // Create a counter, increment it, then get the count
7676 const ref = db . collection ( 'counters' ) . doc ( ) ;
7777 return createCounter ( ref , 10 ) . then ( ( ) => {
78- return incrementCounter ( db , ref , 10 ) ;
78+ return incrementCounter ( ref , 10 ) ;
7979 } ) . then ( ( ) => {
8080 return getCount ( ref ) ;
8181 } ) ;
0 commit comments