Skip to content

Commit

Permalink
refactor: Replace var with let (#46)
Browse files Browse the repository at this point in the history
  • Loading branch information
IvanBila authored and samtstern committed Jun 7, 2019
1 parent d5ed275 commit 9ae3a00
Show file tree
Hide file tree
Showing 3 changed files with 117 additions and 117 deletions.
6 changes: 3 additions & 3 deletions auth/create_custom_tokens.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ admin.initializeApp({
// [END initialize_sdk_with_service_account_id]

// [START custom_token]
var uid = 'some-uid';
let uid = 'some-uid';

admin.auth().createCustomToken(uid)
.then(function(customToken) {
Expand All @@ -26,8 +26,8 @@ admin.auth().createCustomToken(uid)
// [END custom_token]

// [START custom_token_with_claims]
var userId = 'some-uid';
var additionalClaims = {
let userId = 'some-uid';
let additionalClaims = {
premiumAccount: true
};

Expand Down
2 changes: 1 addition & 1 deletion auth/verify_id_tokens.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ admin.initializeApp();
// idToken comes from the client app
admin.auth().verifyIdToken(idToken)
.then(function(decodedToken) {
var uid = decodedToken.uid;
let uid = decodedToken.uid;
// ...
}).catch(function(error) {
// Handle error
Expand Down
Loading

0 comments on commit 9ae3a00

Please sign in to comment.