MDL-22015 Fixing get_string regression
authorDavid Mudrak <david.mudrak@gmail.com>
Tue, 13 Apr 2010 06:22:57 +0000 (06:22 +0000)
committerDavid Mudrak <david.mudrak@gmail.com>
Tue, 13 Apr 2010 06:22:57 +0000 (06:22 +0000)
commitd19e47031c643df2f6f9b55b1d4bb00fdfd2c779
tree1e6b6c7e88854edfb8c04bcda509ad5cbcbcd78a
parentc7b9082a6afa84e0d90d3857c89c71d674bcc711
MDL-22015 Fixing get_string regression

The passed $a placeholder object can be some advanced object like $USER for example.
If such object contained other objects or arrays as properties, casting
to string in the loop throws error. This patch just skips all arrays and
objects when trying to find $a property value.
Thanks to Sam H. for spotting this.
lib/moodlelib.php