In a plugin, I’m trying to find a page using a route which is made up of slugs. For example: /assignments/drafts
.
The challenge here is that the page “Drafts” is a modular page and therefor it’s folder name is _drafts
.
$this->grav['page']->find('/assignments/drafts')
fails but obviously $this->grav['page']->find('/assignments/_drafts')
will succeed.
Is there a built in function that will convert a route containing modular pages to an “expanded” version which includes the underscores?
Many thanks!