diff --git a/google-credential.json b/assets/json/google-credential.json similarity index 100% rename from google-credential.json rename to assets/json/google-credential.json diff --git a/src/modules/configuration/google-calendar/domain/usecases/managers/helpers/create-event-calanedar.helper.ts b/src/modules/configuration/google-calendar/domain/usecases/managers/helpers/create-event-calanedar.helper.ts index 8f674fd..23f82f1 100644 --- a/src/modules/configuration/google-calendar/domain/usecases/managers/helpers/create-event-calanedar.helper.ts +++ b/src/modules/configuration/google-calendar/domain/usecases/managers/helpers/create-event-calanedar.helper.ts @@ -1,6 +1,5 @@ import { google } from 'googleapis'; import * as fs from 'fs'; -import * as path from 'path'; import { TransactionEntity } from 'src/modules/transaction/transaction/domain/entities/transaction.entity'; export async function CreateEventCalendarHelper( @@ -9,11 +8,7 @@ export async function CreateEventCalendarHelper( ) { let result; - const filePath = path.join( - __dirname, - '../../../../../../../../', - 'google-credential.json', - ); + const filePath = './assets/json/google-credential.json'; const credential = JSON.parse(fs.readFileSync(filePath, 'utf8')); const client = new google.auth.JWT({