Skip to content
Snippets Groups Projects
Commit 2dc3e5b1 authored by Laurent Destailleur's avatar Laurent Destailleur
Browse files

Fix: [ bug #1471 ] Several PHP warnings when intercepting USER_CREATE

trigger (Add a protection to avoid multiple errors).
parent a2724822
No related branches found
No related tags found
No related merge requests found
......@@ -345,6 +345,8 @@ class Translate
{
global $db;
if (! is_string($key)) return 'ErrorBadValueForParamNotAString'; // Avoid multiple errors with code not using function correctly.
//print 'xx'.$key;
$newstr=$key;
if (preg_match('/^Currency([A-Z][A-Z][A-Z])$/i',$key,$reg))
......@@ -659,7 +661,7 @@ class Translate
//print 'param: '.$key.'-'.$keydatabase.'-'.$this->trans($key); exit;
// Check if in language array (this can call getTradFromKey)
// Check if a translation is available (this can call getTradFromKey)
if ($this->transnoentitiesnoconv($key) != $key)
{
return $this->transnoentitiesnoconv($key); // Found in language array
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment