Skip to content

Commit

Permalink
Update visionUtils.ts
Browse files Browse the repository at this point in the history
  • Loading branch information
BurhanCantCode authored Aug 2, 2024
1 parent 9e57148 commit cf687c7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions utils/visionUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ import vision from '@google-cloud/vision';
import path from 'path';

const client = new vision.ImageAnnotatorClient({
keyFilename: process.env.GOOGLE_APPLICATION_CREDENTIALS
? path.resolve(process.cwd(), process.env.GOOGLE_APPLICATION_CREDENTIALS)
credentials: process.env.GOOGLE_APPLICATION_CREDENTIALS
? JSON.parse(process.env.GOOGLE_APPLICATION_CREDENTIALS)
: undefined,
});

Expand Down

0 comments on commit cf687c7

Please sign in to comment.