diff --git a/application/controllers/system/Messages.php b/application/controllers/system/Messages.php index 2c2474a1e..36db0238d 100644 --- a/application/controllers/system/Messages.php +++ b/application/controllers/system/Messages.php @@ -10,19 +10,19 @@ class Messages extends VileSci_Controller * */ public function __construct() - { - parent::__construct(); + { + parent::__construct(); - // Loads the message library - $this->load->library('MessageLib'); + // Loads the message library + $this->load->library('MessageLib'); - // Loads the widget library + // Loads the widget library $this->load->library('WidgetLib'); $this->load->model('person/Person_model', 'PersonModel'); $this->_setAuthUID(); // sets property uid - } + } /** * write diff --git a/application/libraries/MessageLib.php b/application/libraries/MessageLib.php index 02ba1e65e..3b5f8093b 100644 --- a/application/libraries/MessageLib.php +++ b/application/libraries/MessageLib.php @@ -746,8 +746,8 @@ class MessageLib $this->ci->BenutzerfunktionModel->addJoin('public.tbl_benutzer', 'uid'); // Get all the valid receivers id using the oe_kurzbz $receivers = $this->ci->BenutzerfunktionModel->loadWhere( - 'oe_kurzbz = \''.$oe_kurzbz.'\''. - ' AND funktion_kurzbz = \''.$this->ci->config->item('assistent_function').'\''. + 'oe_kurzbz = '.$this->ci->db->escape($oe_kurzbz). + ' AND funktion_kurzbz = '.$this->ci->db->escape($this->ci->config->item('assistent_function')). ' AND (NOW() BETWEEN COALESCE(datum_von, NOW()) AND COALESCE(datum_bis, NOW()))' ); diff --git a/content/messages.xul.php b/content/messages.xul.php index 35e279c1d..bdd936d93 100644 --- a/content/messages.xul.php +++ b/content/messages.xul.php @@ -86,8 +86,6 @@ echo ']>