File tree Expand file tree Collapse file tree 2 files changed +7
-5
lines changed Expand file tree Collapse file tree 2 files changed +7
-5
lines changed Original file line number Diff line number Diff line change 11{
22 "name" : " medienbaecker/kirby-modules" ,
33 "description" : " Easily add modules to your pages" ,
4- "version" : " 2.8.1 " ,
4+ "version" : " 2.8.2 " ,
55 "license" : " MIT" ,
66 "authors" : [
77 {
Original file line number Diff line number Diff line change @@ -64,12 +64,14 @@ function createModuleRegistry() {
6464 return Str::replace ($ blueprintName , 'pages/ ' , '' );
6565 }, $ blueprintNames );
6666
67- foreach ($ registry ['blueprints ' ] as $ key => $ blueprint ) {
67+ foreach ($ registry ['blueprints ' ] as & $ blueprint ) {
6868 if (
69- !array_key_exists ('options ' , $ registry ['blueprints ' ][$ key ]) ||
70- !array_key_exists ('changeTemplate ' , $ registry ['blueprints ' ][$ key ]['options ' ])
69+ !isset ($ blueprint ['options ' ]) ||
70+ (
71+ is_array ($ blueprint ['options ' ]) && !isset ($ blueprint ['options ' ]['changeTemplate ' ]
72+ ))
7173 ) {
72- $ registry [ ' blueprints ' ][ $ key ] ['options ' ]['changeTemplate ' ] = $ blueprintNames ;
74+ $ blueprint ['options ' ]['changeTemplate ' ] = $ blueprintNames ;
7375 }
7476 }
7577
You can’t perform that action at this time.
0 commit comments