Skip to content

Commit a60104b

Browse files
author
Theo Ephraim
committed
docs: remove outdated reference to doc.useServiceAccountAuth()
1 parent a7260d8 commit a60104b

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

docs/guides/authentication.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -134,9 +134,10 @@ Here's one way to get it to work (using heroku cli):
134134

135135
And in some other scenarios, replacing newlines in your code can be helpful, for example:
136136
```js
137-
await doc.useServiceAccountAuth({
138-
client_email: process.env.GOOGLE_SERVICE_ACCOUNT_EMAIL,
139-
private_key: process.env.GOOGLE_PRIVATE_KEY.replace(/\\n/g, "\n"),
137+
const jwtFromEnv = new JWT({
138+
email: process.env.GOOGLE_SERVICE_ACCOUNT_EMAIL,
139+
key: process.env.GOOGLE_PRIVATE_KEY.replace(/\\n/g, "\n"),
140+
scopes: SCOPES,
140141
});
141142
```
142143

0 commit comments

Comments
 (0)