Re: [Apps-Script] Drive API - get file metadata - error says null but log shows otherwise

225 views
Skip to first unread message

Laurie J. Nason

unread,
Jun 7, 2022, 4:08:48 AM6/7/22
to google-apps-sc...@googlegroups.com
I think your problem is on line 112 - where you are actually ASSIGNING the value null to getFile - you need the double == to check - and possibly even === 
See if that helps?
Laurie



------ Original Message ------
From "'Clement Chan' via Google Apps Script Community" <google-apps-sc...@googlegroups.com>
To "Google Apps Script Community" <google-apps-sc...@googlegroups.com>
Date 08/11/1443 بعد الهجرة 9:24:39 AM
Subject [Apps-Script] Drive API - get file metadata - error says null but log shows otherwise

Hi everyone, I'm trying to extract the metadata of video files and I keep running into error (no problem when I deal with image files using same set of codes and imageMediaMetadata)

If you see the screenshot, the logger says that there is data in getFile, but according to the error, it's null

If getFile was null, it should have ran the first condition

I'm suspecting that my getFile.width is wrong but I don't know the answer to this - I'm not an experienced coder, just someone who can get basics going.

helpmesomebody.png




--
You received this message because you are subscribed to the Google Groups "Google Apps Script Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-script-c...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-script-community/0958a9d9-2bb3-4363-bf5e-3589ecd75a70n%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages