PHP warning fixes
commit38ad5291a4493e6fb5023fb67f11f15bca70005f
authorerezta <erezta@matrix.co.il>
Wed, 30 Mar 2016 13:42:38 +0000 (30 16:42 +0300)
committerbradymiller <bradymiller@users.sourceforge.net>
Thu, 31 Mar 2016 04:05:38 +0000 (30 21:05 -0700)
tree6e3b6531d3289c891cce779e29d5ed111a305b76
parenta87f7824bd0679152f81227c101958a95a9c3aa2
PHP warning fixes

File: interface/super/rules/controllers/alerts/controller.php

A warning is thrown when entering the alerts page and another error when saving. The issue occurs due to "creating default object from empty val” when instantiating the object.
I’ve added an if condition under isset to check if it’s null before passing the object into the var.

File: interface/main/calendar/modules/PostCalendar/pnadmin.php

PHP7 compatibility error due to function passed by reference. Removed AMPERSAND.

File: controllers/C_Document.class.php

When entering the documents tab in the patient main view an error is thrown, the folder ‘doctemplates’ does not exist at first, as long as no document templates has been uploaded.

Added to controllers/C_Document.class.php check whether the folder exists.

File: library/options.inc.php

When going into admin>alerts there are 2 warnings thrown, one for the first view, and the 2nd one after pressing the save button. This occurs in options.inc.php when optionalAge() function does not receive parameters.
controllers/C_Document.class.php
interface/main/calendar/modules/PostCalendar/pnadmin.php
interface/super/rules/controllers/alerts/controller.php
library/options.inc.php