medienbaecker / kirby-modules

Plugin for modular Kirby websites
MIT License
73 stars 7 forks source link

Removing unnecessary loops #12

Closed iskrisis closed 3 years ago

iskrisis commented 3 years ago

I am pretty sure calling the moduleRegistry() every time was not needed. This would scan modules folder for modules 4 and we need it just once.

There is another loop that could be merged with createModuleRegistry loop here https://github.com/iskrisis/kirby-modules/blob/eefb5d7cc6a977fb689964ec0a03d66c282d27a3/lib/sections/modules.php#L6 but that is not checking filesystem so it doesnt matter that much.

medienbaecker commented 3 years ago

💯