File matched but not processed...

So I have a rule set up that all PDF files that don't have an appendix "-OCR" must be run through with OCR engine of PDFPen. the script looks like this:

the script that it runs is:
the rule status shows that it matched... see:

so for example when i check if my test file matches the rules - it shows that it does... see

but when I see it via the debug log it says:
2019-02-21 12:41:57.045 hazelworker[14514] DEBUG: Screen Shot 2019-02-21 at 11.44.18 AM.png.pdf: Did not match any rules.
while at the same time the rule status menu shows that it matched the file with the rule... see

and the file is not processed... I have no idea why... please help!!!!

the script that it runs is:
- Code: Select all
tell application "PDFpen"
open theFile as alias
tell document 1
ocr
repeat while performing ocr
delay 1
end repeat
delay 1
close with saving
end tell
quit
end tell
the rule status shows that it matched... see:

so for example when i check if my test file matches the rules - it shows that it does... see

but when I see it via the debug log it says:
2019-02-21 12:41:57.045 hazelworker[14514] DEBUG: Screen Shot 2019-02-21 at 11.44.18 AM.png.pdf: Did not match any rules.
while at the same time the rule status menu shows that it matched the file with the rule... see

and the file is not processed... I have no idea why... please help!!!!