Sling Component resource resolver returns null for custom folder
Hello,
I have the problem with locating the folder as resource from Sling Component.
The code looks like the following:

The line 36 gives not null resource object but line 37 gives null.
The folder "/apps/sling" exists initially but "/apps/myfolder" was manually created in JCR Repository Browser.
I compared the properties and access rules of "/apps/sling" and "/apps/myfolder" and was unable to see any difference.
Could you please help me to understand why the custom folder is invisible for resource resolver and how to reach this folder properly during component activation?
Thanks,
Pavel