m8chaa commited on
Commit
cbd4533
·
verified ·
1 Parent(s): 8228971

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -1
app.py CHANGED
@@ -936,6 +936,7 @@ class DriveWatcher:
936
  for user_id, folder_id in self.watch_list.items():
937
  try:
938
  response = await self.create_channel(folder_id)
 
939
  self.channels[response['id']] = {
940
  'resourceId': response['resourceId'],
941
  'user_id': user_id,
@@ -973,7 +974,7 @@ class DriveWatcher:
973
  @app.on_event("startup")
974
  async def startup_event():
975
  app.state.drive_watcher = DriveWatcher()
976
-
977
  # Fetch all users and initialize the watch list
978
  users = users_collection_ref.get()
979
  for user in users:
 
936
  for user_id, folder_id in self.watch_list.items():
937
  try:
938
  response = await self.create_channel(folder_id)
939
+ logging.info(response)
940
  self.channels[response['id']] = {
941
  'resourceId': response['resourceId'],
942
  'user_id': user_id,
 
974
  @app.on_event("startup")
975
  async def startup_event():
976
  app.state.drive_watcher = DriveWatcher()
977
+ app.state.drive_service = build('drive', 'v3', credentials=APICredential)
978
  # Fetch all users and initialize the watch list
979
  users = users_collection_ref.get()
980
  for user in users: