givanz / Vvveb

Powerful and easy to use cms to build websites, blogs or ecommerce stores.
https://www.vvveb.com
GNU Affero General Public License v3.0
239 stars 49 forks source link

Site crashes with PHP error when trying to save new site #96

Open lkthfx opened 3 months ago

lkthfx commented 3 months ago

Steps to reproduce:

  1. go to admin page -> sites list : /index.php?module=settings/sites
  2. press "add site" button
  3. fill forms
  4. press "save site" Result: image

Fix: in /admin/controller/settings/site.php line 149 $site['id'] = $site_id; line 152 list($site, $settings, $site_id, $data) = Event :: trigger(__CLASS__,__FUNCTION__, $site, $settings, $site_id, $data);

givanz commented 3 months ago

Thanks for the bug report, I fixed the warning https://github.com/givanz/Vvveb/commit/b529366154c6b89b8583f15c4d50149f5c1ac3cc

Twilight-Computer commented 3 months ago

Line 52 should read $setting not $settings as shown above - just in case someone copies that line :-)

givanz commented 3 months ago

Thanks for pointing out, I fixed wrong event parameters https://github.com/givanz/Vvveb/commit/3a2cfc6fd7e038b3446ed92e974f487e5929d474.