Unable to detect JavaScript in pdf with Java

Hello,

I am trying to detect the JavaScript in a pdf as described here Determine if Javascript present in a PDF file - #3 by mlittle4444.

I tried the document level check. I am getting an empty list when try the command pdfdoc.getJavaScript().getKeys(). I have a document that I can provide for this issue, but It might contain sensitive information, so I can only share it via a secure upload. Thank you for your help.

Regards,

@farisn

Please share your sample PDF and full code snippet that you have used so that we can test the scenario in our environment and address it accordingly.