andrewhoule / silverstripe-photogallery

Simple photo gallery with albums for Silverstripe
BSD 3-Clause "New" or "Revised" License
11 stars 13 forks source link

move include template to correct location #17

Closed andrewandante closed 6 years ago

andrewandante commented 6 years ago

Fixes error when loading PhotogalleryPage with an album.

andrewhoule commented 6 years ago

I just did some testing... I can't replicate that error on my branch, but moving PhotoItems.ss to templates/Includes does cause an error. Could you show me a screenshot of the error you're getting?

andrewandante commented 6 years ago

Hi - sorry, I should know better than to leave an empty PR message like that!

The error message received is:

USER WARNING] NONE OF THE FOLLOWING TEMPLATES COULD BE FOUND: ARRAY ( [0] => ARRAY ( [TYPE] => INCLUDES [0] => PHOTOITEMS ) [1] => PHOTOITEMS ) IN THEMES "ARRAY ( [0] => SIMPLE [1] => $DEFAULT ) "

To reproduce:

The issue came up when I was helping a user on the SilverStripe User's Slack channel who experienced the same issue with a Framework 4.0.3 install

andrewhoule commented 6 years ago

Oh!!! Now I see it, thanks!

So I just pushed up an update that should fix that. I chose to fix the path (for namespacing sake) rather than move the file, but that should do the trick.